Skip to content

Commit

Permalink
Revert "Merge pull request #68 from philippgille/stop-exporting-opena…
Browse files Browse the repository at this point in the history
…i-baseurl"

This reverts commit 04d0fd5, reversing
changes made to 6886041.
  • Loading branch information
philippgille committed Apr 25, 2024
1 parent bf0448d commit f10845b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions embed_openai.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"sync"
)

const baseURLOpenAI = "https://api.openai.com/v1"
const BaseURLOpenAI = "https://api.openai.com/v1"

type EmbeddingModelOpenAI string

Expand Down Expand Up @@ -42,7 +42,7 @@ func NewEmbeddingFuncDefault() EmbeddingFunc {
func NewEmbeddingFuncOpenAI(apiKey string, model EmbeddingModelOpenAI) EmbeddingFunc {
// OpenAI embeddings are normalized
normalized := true
return NewEmbeddingFuncOpenAICompat(baseURLOpenAI, apiKey, string(model), &normalized)
return NewEmbeddingFuncOpenAICompat(BaseURLOpenAI, apiKey, string(model), &normalized)
}

// NewEmbeddingFuncOpenAICompat returns a function that creates embeddings for a text
Expand Down

0 comments on commit f10845b

Please sign in to comment.