[feat] added streaming partly

This commit is contained in:
kwaroran
2023-05-17 03:11:34 +09:00
parent 502ffa7314
commit 7ea4945088
5 changed files with 29 additions and 5 deletions

View File

@@ -337,6 +337,9 @@ export async function sendChat(chatProcessIndex = -1):Promise<boolean> {
if(req.type === 'fail'){
alertError(req.result)
return false
}
else if(req.type === 'streaming'){
}
else{
const result2 = processScriptFull(currentChar, reformatContent(req.result), 'editoutput')
@@ -429,8 +432,8 @@ export async function sendChat(chatProcessIndex = -1):Promise<boolean> {
maxTokens: 30,
}, 'submodel')
if(rq.type === 'fail'){
alertError(rq.result)
if(rq.type === 'fail' || rq.type === 'streaming'){
alertError(`${rq.result}`)
return true
}
else{