future-glass-56154
09/16/2025, 9:46 PMtall-airline-16756
09/16/2025, 9:46 PMtall-airline-16756
09/16/2025, 9:46 PMfuture-glass-56154
09/16/2025, 9:47 PMtall-airline-16756
09/16/2025, 9:47 PMuse_tts_aligned_transcript=True in your AgentSession configuration.
• Then, implement the transcription_node method in your agent class to handle TimedString objects, which include helpful start_time and end_time fields.
async def transcription_node(
self, text: AsyncIterable[str | TimedString], model_settings: ModelSettings
) -> AsyncGenerator[str | TimedString, None]:
async for chunk in text:
if isinstance(chunk, TimedString):
<http://logger.info|logger.info>(f"TimedString: '{chunk}' ({chunk.start_time} - {chunk.end_time})")
yield chunk
Just a quick note: this feature is experimental and currently available only in Python.
For User Utterances:
• You can tap into the user_input_transcribed event to get transcription data with timing info, provided your STT provider supports it (like the Gladia STT plugin).
• Also, telemetry attributes such as lk.start_time and lk.end_time are great for tracking speaking spans.
Frontend Access:
• Try using useVoiceAssistant() for agent transcriptions and useTrackTranscription() for user transcriptions.
• By combining these and sorting them by firstReceivedTime, you can beautifully reconstruct the conversation timeline.
If you'd like, I'm here to walk you through any part of the implementation or provide more details. Just let me know!
Sources: Text and transcriptions | LiveKit Docs | livekit-plugins/livekit-plugins-google/livekit/plugins/google/stt.py | complex-agents/nutrition-assistant/nutrition-assistant-frontend/hooks/useCo... | Understanding Transcript Timing in Voice Conversations