mirror of
https://github.com/open-webui/open-webui.git
synced 2025-12-16 20:07:49 +01:00
refac: audio
This commit is contained in:
@@ -324,11 +324,11 @@ def get_embedding_model_path(
|
||||
|
||||
|
||||
def generate_openai_embeddings(
|
||||
model: str, text: str, key: str, url: str = "https://api.openai.com"
|
||||
model: str, text: str, key: str, url: str = "https://api.openai.com/v1"
|
||||
):
|
||||
try:
|
||||
r = requests.post(
|
||||
f"{url}/v1/embeddings",
|
||||
f"{url}/embeddings",
|
||||
headers={
|
||||
"Content-Type": "application/json",
|
||||
"Authorization": f"Bearer {key}",
|
||||
|
||||
Reference in New Issue
Block a user