fix: empty response
This commit is contained in:
parent
8c83fe23a1
commit
4a8e85c28a
|
@ -135,7 +135,7 @@ export class ChatGPTApi implements LLMApi {
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
return res.choices?.at(0)?.message?.content ?? "";
|
return res.choices?.at(0)?.message?.content ?? res;
|
||||||
}
|
}
|
||||||
|
|
||||||
async chat(options: ChatOptions) {
|
async chat(options: ChatOptions) {
|
||||||
|
|
Loading…
Reference in New Issue