cohere

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2026 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Overview

Package cohere implements embeddings using Cohere's Embed API v2.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BaseURL   string
	APIKey    string
	Model     string
	InputType string
	Client    *http.Client
}

type Embedder

type Embedder struct {
	// contains filtered or unexported fields
}

func New

func New(cfg Config) *Embedder

func (*Embedder) Embed

func (e *Embedder) Embed(ctx context.Context, texts []string) ([][]float32, error)

Jump to

Keyboard shortcuts

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