mirror of
https://github.com/ikechan8370/chatgpt-plugin.git
synced 2025-12-16 13:27:08 +00:00
fix: API3 conversation bug
This commit is contained in:
parent
4ba1c80cc0
commit
bd934fd970
1 changed files with 4 additions and 2 deletions
|
|
@ -18,7 +18,7 @@ export class OfficialChatGPTClient {
|
|||
async sendMessage (prompt, opts = {}) {
|
||||
let {
|
||||
timeoutMs = this._timeoutMs,
|
||||
conversationId = uuidv4(),
|
||||
conversationId,
|
||||
parentMessageId = uuidv4(),
|
||||
messageId = uuidv4(),
|
||||
action = 'next'
|
||||
|
|
@ -40,10 +40,12 @@ export class OfficialChatGPTClient {
|
|||
}
|
||||
}
|
||||
],
|
||||
conversation_id: conversationId,
|
||||
model: Config.plus ? 'text-davinci-002-render-sha' : 'text-davinci-002-render-sha',
|
||||
parent_message_id: parentMessageId
|
||||
}
|
||||
if (conversationId) {
|
||||
body.conversation_id = conversationId
|
||||
}
|
||||
let option = {
|
||||
method: 'POST',
|
||||
body: JSON.stringify(body),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue