mirror of
https://github.com/Mintplex-Labs/anything-llm.git
synced 2025-04-17 18:18:11 +00:00
Fix TypeError by replacing this.openai.createChatCompletion with the correct function call (#2117)
fixed new api syntax
This commit is contained in:
parent
bdf37bf180
commit
4365d69359
1 changed files with 1 additions and 1 deletions
|
@ -80,7 +80,7 @@ class HuggingFaceLLM {
|
|||
}
|
||||
|
||||
async getChatCompletion(messages = null, { temperature = 0.7 }) {
|
||||
const result = await this.openai.createChatCompletion({
|
||||
const result = await this.openai.chat.completions.create({
|
||||
model: this.model,
|
||||
messages,
|
||||
temperature,
|
||||
|
|
Loading…
Add table
Reference in a new issue