Live data from Hacker News

Show HN: Open source framework OpenAI uses for Advanced Voice

github.com

1–10 of 63 posts

Show HN: Open source framework OpenAI uses for Advanced Voice

#1
Hey HN, we've been working with OpenAI for the past few months on the new Realtime API.

The goal is to give everyone access to the same stack that underpins Advanced Voice in the ChatGPT app.

Under the hood it works like this: - A user's speech is captured by a LiveKit client SDK in the ChatGPT app - Their speech is streamed using WebRTC to OpenAI’s voice agent - The agent relays the speech prompt over websocket to GPT-4o - GPT-4o runs inference and streams speech packets (over websocket) back to the agent - The agent relays generated speech using WebRTC back to the user’s device

The Realtime API that OpenAI launched is the websocket interface to GPT-4o. This backend framework covers the voice agent portion. Besides having additional logic like function calling, the agent fundamentally proxies WebRTC to websocket.

The reason for this is because websocket isn’t the best choice for client-server communication. The vast majority of packet loss occurs between a server and client device and websocket doesn’t provide programmatic control or intervention in lossy network environments like WiFi or cellular. Packet loss leads to higher latency and choppy or garbled audio.

Show HN: Open source framework OpenAI uses for Advanced Voice
github.com

Re: Show HN: Open source framework OpenAI uses for Advanced Voice

#3
Nice they have many partners on this. I see Azure as well.

There is a common consensus that the new Realtime API is not actually using the same Advanced Voice model / engine - or however it works - since at least the TTS part doesn’t seem to be as capable as the one shipped with the official OpenAI app.

Any idea on this?

Source: https://github.com/openai/openai-realtime-api-beta/issues/2

Re: Show HN: Open source framework OpenAI uses for Advanced Voice

#5
Super cool! Didn't realize OpenAI is just using LiveKit.

Does the pricing breakdown to be the same as having a OpenAI Advanced Voice socket open the whole time? It's like $9/hr!

It would be theoretically cheaper to use this without keeping the advanced voice socket open the whole time and just use the GPT4o streaming service [1] for whenever inference is needed (pay per token) and use livekits other components to do the rest (TTS, VAD etc.).

What's the trade off here?

[1]: https://platform.openai.com/docs/api-reference/streaming

Re: Show HN: Open source framework OpenAI uses for Advanced Voice

#7
post #5

Super cool! Didn't realize OpenAI is just using LiveKit. Does the pricing breakdown to be the same as having a OpenAI Advanced Voice socket open the whole time? It's like $9/hr! It would be theoretically cheaper to use this without keeping the advanced voice socket open the whole time and just use the GPT4o streaming service [1] for whenever inference is needed (pay per token) and use livekits other components to do…

Currently it does: all audio is sent to the model.

However, we are working on turn detection within the framework, so you won't have to send silence to the model when the user isn't talking. It's a fairly straight forward path to cutting down the cost by ~50%.

Re: Show HN: Open source framework OpenAI uses for Advanced Voice

#9

Nice they have many partners on this. I see Azure as well. There is a common consensus that the new Realtime API is not actually using the same Advanced Voice model / engine - or however it works - since at least the TTS part doesn’t seem to be as capable as the one shipped with the official OpenAI app. Any idea on this? Source: https://github.com/openai/openai-realtime-api-beta/issues/2

It's using the same model/engine. I don't have knowledge of the internals, but a different subsystem/set of dedicated resources though for API traffic versus first-party apps.

One thing to note is there is no separate TTS-phase here, it's happening internally within GPT-4o, in the Realtime API and Advanced Voice.

Post reply on HN