Skip to content

Commit e6ef534

Browse files
committed
fix: update to support lazyloader (server)
1 parent 03d5f5d commit e6ef534

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/client.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ async function send(conversation) {
6464
let data = await crud.socket.send({
6565
method: 'openai.chat.completions.create',
6666
action: 'chat',
67-
chat: {
67+
openai: {
6868
messages: conversation,
6969
max_tokens,
7070
temperature,
@@ -75,7 +75,7 @@ async function send(conversation) {
7575
})
7676

7777
if (data) {
78-
let content = data.chat.choices[0].message.content;
78+
let content = data.openai.choices[0].message.content;
7979
content = content.replace(/```json\n|\n```/g, '');
8080
content = JSON.parse(content)
8181

0 commit comments

Comments
 (0)