Browse Source

Add speech started topic

make-qwen-llm-configurable
haixuantao 5 months ago
parent
commit
4743061d7f
3 changed files with 6 additions and 6 deletions
  1. +2
    -2
      examples/openai-realtime/whisper-template-metal.yml
  2. +1
    -1
      node-hub/dora-distil-whisper/dora_distil_whisper/main.py
  3. +3
    -3
      node-hub/dora-openai-websocket/src/main.rs

+ 2
- 2
examples/openai-realtime/whisper-template-metal.yml View File

@@ -4,7 +4,7 @@ nodes:
inputs:
audio: tts/audio
text: stt/text
stop: stt/stop
speech_started: stt/speech_started
outputs:
- audio
- text
@@ -31,7 +31,7 @@ nodes:
outputs:
- text
- word
- stop
- speech_started

- id: llm
build: pip install -e ../../node-hub/dora-qwen


+ 1
- 1
node-hub/dora-distil-whisper/dora_distil_whisper/main.py View File

@@ -268,7 +268,7 @@ def main():
pa.array([text]),
)
node.send_output(
"stop",
"speech_started",
pa.array([text]),
)
cache_audio = None


+ 3
- 3
node-hub/dora-openai-websocket/src/main.rs View File

@@ -367,10 +367,10 @@ async fn handle_client(fut: upgrade::UpgradeFut) -> Result<(), WebSocketError> {
.into(),
));
frame
} else if id.contains("stop") {
} else if id.contains("") {
let serialized_data =
OpenAIRealtimeResponse::InputAudioBufferSpeechStopped {
audio_end_ms: 123,
OpenAIRealtimeResponse::InputAudioBufferSpeechStarted {
audio_start_ms: 123,
item_id: "123".to_string(),
};
finished = true;


Loading…
Cancel
Save