Skip to content
This repository was archived by the owner on May 10, 2024. It is now read-only.

Commit 02d2430

Browse files
authored
Update embeddings.md
Without "api_version" will raise an error like this: "MyProjectPath/openai/api_resources/abstract/engine_api_resource.py", line 37, in class_url raise error.InvalidRequestError( TypeError: __init__() missing 1 required positional argument: 'param' Corresponding code: if not api_version: raise error.InvalidRequestError( "An API version is required for the Azure API type." ) Please take a look ~
1 parent 0ed1bcd commit 02d2430

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

docs/embeddings.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,7 @@ openai_ef = embedding_functions.OpenAIEmbeddingFunction(
127127
api_key="YOUR_API_KEY",
128128
api_base="YOUR_API_BASE_PATH",
129129
api_type="azure",
130+
api_version="YOUR_API_VERSION",
130131
model_name="text-embedding-ada-002"
131132
)
132133
```

0 commit comments

Comments
 (0)