Versions in this module Expand all Collapse all v0 v0.8.0 Mar 29, 2026 Changes in this version + type BuiltinEmbedder struct + OnModelEvent func(eventType string) + func NewBuiltinEmbedder(modelsDir string) *BuiltinEmbedder + func NewBuiltinEmbedderWithPoolSize(modelsDir string, poolSize int) *BuiltinEmbedder + func (b *BuiltinEmbedder) Close() error + func (b *BuiltinEmbedder) Embed(ctx context.Context, text string) ([]float32, error) + func (b *BuiltinEmbedder) EmbedBatch(ctx context.Context, texts []string) ([][]float32, error) + func (b *BuiltinEmbedder) Model() string + func (b *BuiltinEmbedder) StatusDetail() string + func (b *BuiltinEmbedder) WarmUp(ctx context.Context) error + type Client struct + func NewClient(endpoint, model string, opts ...Option) *Client + func (c *Client) Embed(ctx context.Context, text string) ([]float32, error) + func (c *Client) EmbedBatch(ctx context.Context, texts []string) ([][]float32, error) + func (c *Client) Model() string + func (c *Client) WarmUp(_ context.Context) error + type Embedder interface + Close func() error + Embed func(ctx context.Context, text string) ([]float32, error) + Model func() string + WarmUp func(ctx context.Context) error + type HTTPDoer interface + Do func(*http.Request) (*http.Response, error) + type OllamaEmbedder struct + func NewOllamaEmbedder(endpoint, model string, opts ...Option) *OllamaEmbedder + func (o *OllamaEmbedder) Close() error + func (o *OllamaEmbedder) Embed(ctx context.Context, text string) ([]float32, error) + func (o *OllamaEmbedder) Model() string + func (o *OllamaEmbedder) WarmUp(ctx context.Context) error + type Option func(*Client) + func WithHTTPDoer(d HTTPDoer) Option