Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interruption of assistant in VAD mode not working #54

Open
SuperNiceDev opened this issue Oct 22, 2024 · 4 comments
Open

Interruption of assistant in VAD mode not working #54

SuperNiceDev opened this issue Oct 22, 2024 · 4 comments

Comments

@SuperNiceDev
Copy link

In VAD mode it seems you cannot interrupt the assistant. It makes a short break, but then keeps on going.

@Cazforshort
Copy link

I agree, this seems to be a common issue. It also seems to interrupt itself a lot.

@SuperNiceDev
Copy link
Author

Thanks for the confirmation.

@Cazforshort
Copy link

I was able to get it working pretty well. Heres how

  1. System constantly processes microphone input at regular intervals (every 0.1 seconds)
  2. Input is converted to PCM16 format and sent to OpenAI's server
  3. Server performs Voice Activity Detection (VAD)

User speaks during AI audio →
→ Server detects speech ("input_audio_buffer.speech_started" event) →
→ AudioManager stops current audio playback
→ System cancels active response
→ All states reset (isResponseActive, activeResponseId, etc.)
→ System ready for new interaction

@aarizirf
Copy link

aarizirf commented Dec 3, 2024

are you hosting the client on an external server? Or are you implementing it client side?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants