Can you get the transcript from Google real-time A...
# ask-ai
m
Can you get the transcript from Google real-time API?
t
Thanks for reaching out, Rishabh. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Absolutely! LiveKit can work seamlessly with the Google Real-time API to get transcripts of user audio input. This happens through the
RealtimeModel
class in the LiveKit Google plugin. It lets you capture real-time transcriptions of audio, and you can easily handle those transcription events right in your app. Here’s a quick way to get started: 1. Install the LiveKit Google plugin with:
pip install "livekit-agents[google]~=1.2"
2. Set up your Google API credentials—either with an API key or a service account JSON key file. 3. Turn on transcription by setting the
input_audio_transcription
parameter when you initialize the
RealtimeModel
. 4. Watch for the
input_audio_transcription_completed
event to grab the transcript. If you want me to walk you through any part of this or have questions, just give me a shout—I’m here to help! Sources: Google Cloud STT integration guide | LiveKit Docs | Gemini Live API integration guide | LiveKit Docs | livekit-plugins/livekit-plugins-google/livekit/plugins/google/beta/realtime... | Google AI and LiveKit | LiveKit Docs
m
Give me an example in Python both for input audio transcription and output audio transcription and also tell me how to handle the events using agent's API.
t
I don't have the answer you're looking for. You could also try asking your question: • in one of the other Slack channels or • to https://deepwiki.com/livekit/livekit_composite which is trained on all LiveKit source code If you find the answer, please post it here to help others!