modelsext

package
v1.32.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 6, 2025 License: BSD-3-Clause Imports: 1 Imported by: 0

Documentation

Overview

Package modelsext provides extension methods to the structures in the models package. As this package is generated, we cannot put any functionality or helper methods straight into it.

As the models package is used very widely throughout the repository, extensions package should not import anything outside the models package as well to avoid any circular dependencies.

To keep things tidy, use these conventions: 1. Helpers for the struct in models/X.go should be in modelsext/X.go . 2. Functions should be named <struct name><aspirational method name>.

Index

Constants

View Source
const DefaultNamedVectorName = "default"

DefaultNamedVectorName is a default vector named used to create a named vector or to allow access to legacy vector through named vector API.

Variables

This section is empty.

Functions

func ClassGetVectorConfig

func ClassGetVectorConfig(class *models.Class, targetVector string) (models.VectorConfig, bool)

ClassGetVectorConfig returns the vector config for a given class and target vector. There is a special case for the default vector name, which is used to access the legacy vector.

func ClassHasLegacyVectorIndex

func ClassHasLegacyVectorIndex(class *models.Class) bool

ClassHasLegacyVectorIndex checks whether there is a legacy index configured on a class.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL