Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Embedder ¶
type Embedder interface { EmbedDocuments(ctx context.Context, texts []string) ([][]float32, error) EmbedQuery(ctx context.Context, text string) ([]float32, error) }
Embedder is an interface matching github.com/tmc/langchaingo embedder used for generating embeddings for a single document and a batch
type OpenAIClient ¶
type OpenAIClient struct {
// contains filtered or unexported fields
}
func NewOpenAIClient ¶
func NewOpenAIClient(key string) OpenAIClient
func NewOpenAIClientWithHTTP ¶
func NewOpenAIClientWithHTTP(openAIEndpoint, key string, client *http.Client) OpenAIClient
func (*OpenAIClient) EmbedDocuments ¶ added in v1.4.0
func (*OpenAIClient) EmbedQuery ¶ added in v1.4.0
Click to show internal directories.
Click to hide internal directories.