batchtext

package
v1.34.9 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2026 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BatchTextVectorizer

type BatchTextVectorizer[T dto.Embedding] struct {
	// contains filtered or unexported fields
}

func (*BatchTextVectorizer[T]) Object

func (*BatchTextVectorizer[T]) Objects

func (*BatchTextVectorizer[T]) Texts

func (v *BatchTextVectorizer[T]) Texts(ctx context.Context,
	inputs []string, cfg moduletools.ClassConfig,
) (T, error)

type Client

type Vectorizer

type Vectorizer[T dto.Embedding] interface {
	Texts(ctx context.Context,
		input []string, cfg moduletools.ClassConfig,
	) (T, error)
	Object(ctx context.Context,
		obj *models.Object, cfg moduletools.ClassConfig,
	) (T, models.AdditionalProperties, error)
	Objects(ctx context.Context,
		objs []*models.Object, cfg moduletools.ClassConfig,
	) ([]T, models.AdditionalProperties, error)
}

func New

func New[T dto.Embedding](moduleName string, lowerCaseInput bool, client Client[T]) Vectorizer[T]

func NewWithAltNames

func NewWithAltNames[T dto.Embedding](moduleName string, altNames []string, lowerCaseInput bool, client Client[T]) Vectorizer[T]

Jump to

Keyboard shortcuts

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