mirror of
https://github.com/open-webui/open-webui.git
synced 2026-10-14 04:08:46 +00:00
Merge 86de14cff9 into 83dcc2dbea
This commit is contained in:
commit
00dc8ec923
2 changed files with 3 additions and 4 deletions
|
|
@ -413,7 +413,7 @@ async def realtime_call(ws: WebSocket):
|
|||
# every function call an unambiguous input_item_id, even during barge-in.
|
||||
'turn_detection': {
|
||||
'type': 'server_vad',
|
||||
'interrupt_response': True,
|
||||
'interrupt_response': False,
|
||||
'create_response': False,
|
||||
},
|
||||
},
|
||||
|
|
|
|||
|
|
@ -352,7 +352,6 @@ export class RealtimeCall {
|
|||
} else if (type === 'input_audio_buffer.speech_started') {
|
||||
this.receivingSpeech = event.item_id;
|
||||
this.userSpeaking = !this.muted;
|
||||
this.stopSpeaking();
|
||||
} else if (type === 'input_audio_buffer.speech_stopped') {
|
||||
if (this.receivingSpeech === event.item_id) this.userSpeaking = false;
|
||||
} else if (
|
||||
|
|
@ -375,6 +374,7 @@ export class RealtimeCall {
|
|||
this.flush();
|
||||
return;
|
||||
}
|
||||
this.stopSpeaking();
|
||||
const session = this.session;
|
||||
const modelId = this.options.context().modelId;
|
||||
this.savingHistory++;
|
||||
|
|
@ -453,8 +453,7 @@ export class RealtimeCall {
|
|||
if (this.animationCalls.has(event.item.call_id)) return;
|
||||
this.animationCalls.add(event.item.call_id);
|
||||
let status = 'unavailable';
|
||||
if (!response || this.interrupted.has(event.response_id) || this.receivingSpeech)
|
||||
status = 'cancelled';
|
||||
if (!response || this.interrupted.has(event.response_id)) status = 'cancelled';
|
||||
else {
|
||||
try {
|
||||
const args = JSON.parse(event.item.arguments);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue