Skip to content
Snippets Groups Projects
Commit 978ef781 authored by swk777's avatar swk777
Browse files

Fix OpenAIEmbedding Fails to Retrieve Session from Parameters When Not Using Azure

parent 18b8915f
Branches
Tags
No related merge requests found
...@@ -259,11 +259,13 @@ export class OpenAIEmbedding extends BaseEmbedding { ...@@ -259,11 +259,13 @@ export class OpenAIEmbedding extends BaseEmbedding {
}); });
} else { } else {
this.apiKey = init?.apiKey ?? undefined; this.apiKey = init?.apiKey ?? undefined;
this.session = getOpenAISession({ this.session =
apiKey: this.apiKey, init?.session ??
maxRetries: this.maxRetries, getOpenAISession({
timeout: this.timeout, apiKey: this.apiKey,
}); maxRetries: this.maxRetries,
timeout: this.timeout,
});
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment