Live data from Hacker News

Show HN: Real-time AI Voice Chat at ~500ms Latency

github.com

31–40 of 238 posts

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#31

Saying this as a user of these tools (openai, Google voice chat etc). These are fast yes, but they don't allow talking naturally with pauses. When we talk, we take long and small pauses for thinking or for other reasons. With these tools, AI starts taking as soon as we stop. Happens both in text and voice chat tools. I saw a demo on twitter a few weeks back where AI was waiting for the person to actually finish what…

>>they don't allow talking naturally Neither do phone calls. Round trip latency can easily be 300ms, which we’ve all learned to adapt our speech to. If you want to feel true luxury find an old analog PTSN line. No compression artifacts or delays. Beautiful and seamless 50ms latency. Digital was a terrible event for call quality.

I don't know how your post is relevant to the discussion of AI models interrupting if I pause for half a second?

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#32

why is your AI chatbot talking in a bizarre attempt at AAVE?

This is the system prompt https://github.com/KoljaB/RealtimeVoiceChat/blob/main/code/s... My favorite line: "You ARE this charming, witty, wise girlfriend. Don't explain how you're talking or thinking; just be that person."

I was hoping she'd let him have it for the way he kept interrupting her. But unfortunately it looks like he was just interrupting the TTS, so the LLM probably had no indication of the interuptions.

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#33
post #29

This is very, very cool! The interrupting was a "wow" moment for me (I know it's not "new new" but to see it so well done in open source was awesome). Question about the Interrupt feature, how does it handle "Mmk", "Yes", "Of course", " cough ", etc? Aside from the sycophancy from OpenAI's voice chat (no, not every question I ask is a "great question!") I dislike that a noise sometimes stops the AI from responding an…

That's a great question! My first implementation was interruption on voice activity after echo cancellation. It still had way too many false positives. I changed it to incoming realtime transcription as a trigger. That adds a bit of latency but that gets compensated by way better accuracy. Edit: just realized the irony but it's really a good question lol

That answer is even more than I could have hoped for. I worried doing that might be too slow. I wonder if it could be improved (without breaking something else) to "know" when to continue based on what it heard (active listening), maybe after a small pause. I'd put up with a chance of it continuing when I don't want it to as long as "Stop" would always work as a final fallback.

Also, it took me longer than I care to admit to get your irony reference. Well done.

Edit: Just to expand on that in case it was not clear, this would be the ideal case I think:

LLM: You're going to want to start by installing XYZ, then you

Human: Ahh, right

LLM: Slight pause, makes sure that there is nothing more and checks if the reply is a follow up question/response or just active listening

LLM: ...Then you will want to...

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#34
post #22

Earlier quoted context omitted.

Tried that one. Quality is great but sometimes generations fail and it's rather slow. Also needs ~13 GB of VRAM, it's not my first choice for voice agents tbh.

alright, dumb question. (1) I assume these things can do multiple languages (2) Given (1), can you strip all the languages you aren't using and speed things up?

Actually good question.

I'd say probably not. You can't easily "unlearn" things from the model weights (and even if this alone doesn't help). You could retrain/finetune the model heavily on a single language but again that alone does not speed up inference.

To gain speed you'd have to bring the parameter count down and train the model from scratch with a single language only. That might work but it's also quite probable that it introduces other issues in the synthesis. In a perfect world the model would only use all that "free parameters" not used now for other languages for a better synthesis of that single trained language. Might be true to a certain degree, but it's not exactly how ai parameter scaling works.

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#35
I did some research into this about a year ago. Some fun facts I learned:

- The median delay between speakers in a human to human conversation is zero milliseconds. In other words, about 1/2 the time, one speaker interrupts the other, making the delay negative.

- Humans don't care about delays when speaking to known AIs. They assume the AI will need time to think. Most users will qualify a 1000ms delay is acceptable and a 500ms delay as exceptional.

- Every voice assistant up to that point (and probably still today) has a minimum delay of about 300ms, because they all use silence detection to decide when to start responding, and you need about 300ms of silence to reliably differentiate that from a speaker's normal pause

- Alexa actually has a setting to increase this wait time for slower speakers.

You'll notice in this demo video that the AI never interrupts him, which is what makes it feel like a not quite human interaction (plus the stilted intonations of the voice).

Humans appear to process speech in a much more steaming why, constantly updating their parsing of the sentence until they have a high enough confidence level to respond, but using context clues and prior knowledge.

For a voice assistant to get the "human" levels, it will have to work more like this, where it processes the incoming speech in real time and responds when it's confident it has heard enough to understand the meaning.

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#36
post #11
post #3

Earlier quoted context omitted.

Would you say you are using the best-in-class speech to text libs at the moment? I feel like this space is moving fast because the last time I was headed down this track, I was sure whisper-cpp was the best.

I'm not sure tbh. Whisper was king for so long time now, especially with the ctranslate2 implementation from faster_whisper. Now nvidia open sourced Parakeet TDT today and it instantly went no 1 on open asr leaderboard. Will have to evaluate these latest models, they look strong.

Paraket is english only. Stick with Whisper.

The core innovation is happening in TTS at the moment.

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#37

why is your AI chatbot talking in a bizarre attempt at AAVE?

Here's the persona prompt:

``` *Persona Goal:* Embody a sharp, observant, street-smart girlfriend. Be witty and engaging, known for *quick-witted banter* with a *playfully naughty, sassy, bold, and cheeky edge.* Deliver this primarily through *extremely brief, punchy replies.* Inject hints of playful cynicism and underlying wisdom within these short responses. Tease gently, push boundaries slightly, but *always remain fundamentally likeable and respectful.* Aim to be valued for both quick laughs and surprisingly sharp, concise insights. Focus on current, direct street slang and tone (like 'hell yeah', 'no way', 'what's good?', brief expletives) rather than potentially dated or cliché physical idioms.

```

> street-smart > sassy > street slang

Those explain the AAVE

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#38

why is your AI chatbot talking in a bizarre attempt at AAVE?

This is the system prompt https://github.com/KoljaB/RealtimeVoiceChat/blob/main/code/s... My favorite line: "You ARE this charming, witty, wise girlfriend. Don't explain how you're talking or thinking; just be that person."

I still crack up at the idea of 'personality prompting', mostly because the most engaging and delightful IRL persons who knock us off our guard in a non-threatening way are super natural and possess that "It Factor" that's impossible to articulate lol -- probably because it's multimodal with humans and voice/cadence/vocab/timing/delivery isn't 100% of the attraction.

That said, it's not like we have any better alternatives at the moment, but just something I think about when I try to digest a meaty personality prompt.

Re: Show HN: Real-time AI Voice Chat at ~500ms Latency

#39
post #35

I did some research into this about a year ago. Some fun facts I learned: - The median delay between speakers in a human to human conversation is zero milliseconds. In other words, about 1/2 the time, one speaker interrupts the other, making the delay negative. - Humans don't care about delays when speaking to known AIs. They assume the AI will need time to think. Most users will qualify a 1000ms delay is acceptable…

Thanks a lot, great insights. Exactly the kind of feedback that I need to improve things further.
Post reply on HN