<@U07FRRZH2GN> how can we capture emails effective...
# ask-ai
f
@icy-policeman-64898 how can we capture emails effectively over call
t
Thanks for reaching out, Abhishek. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Thanks — you’re asking how to capture emails effectively over calls. I’ll focus on what you can do with LiveKit and practical best practices that improve accuracy and completion. Short answer • Use the prebuilt GetEmailTask to collect and validate email addresses during a voice interaction. It normalizes common speech forms (e.g., “dot”, “at”, spelled-out letters) and returns a validated structured email result. • Combine GetEmailTask with short consent or fallback tasks (TaskGroup) so you can confirm permission and record an alternate contact if the caller refuses. How to implement (high level) 1. Use GetEmailTask during the call ◦ Call GetEmailTask with the conversation context so it can refer to prior turns and parse noisy transcriptions. ◦ The task returns a structured result with the validated
email_address
. 1. Add a consent step and fallbacks ◦ Put a consent collection task before email capture to record permission. ◦ If a user refuses, invoke a fallback tool (example: collect phone number or SMS opt-in) so you still capture a contact method. 1. Keep prompts short and guided ◦ Use concise prompts like: “May I get your email to send that information?” then “Please say or spell your email address.” ◦ If a user spells, accept both natural speech (“john at gmail dot com”) and letter-by-letter spelling. 1. Improve accuracy ◦ Use a multilingual or improved end-of-turn model to reduce interruptions and better handle structured data like emails. ◦ Normalize common words: treat “dot” → “.”, “underscore” → “_”, and interpret “at” → “@”. 1. Log and store results ◦ Record whether consent was given and the collected email for compliance and auditing. ◦ Persist the structured email result returned by GetEmailTask rather than raw transcription. Example patterns (conceptual) 1. Single-step: ◦ Prompt: “Can I get your email to send a copy?” → run GetEmailTask → save
email_address
. 1. Consent + email: ◦ Task 1: CollectConsent ◦ Task 2: GetEmailTask ◦ Save both consent flag and email to session record. 1. Fallback flow: ◦ If user declines email: run custom tool to collect alternate contact info (phone/SMS). ◦ Example tool can store alternate contact and generate a brief confirmation reply. Customization • Add
extra_instructions
to GetEmailTask to tailor phrasing. • Supply custom
tools
(e.g., a get_alternate_contact_info tool) to handle cases like refusal or ambiguous responses. Next steps I can help with • Show a concise code example wiring GetEmailTask into your agent flow. • Help design prompts for your call script (short, multilingual-friendly). • Suggest how to store the structured result and consent flags in your database. Would you like a code sample for your specific agent framework or a suggested call script tailored to your industry (support, sales, healthcare, etc.)? Sources: GetEmailTask | LiveKit Documentation | Collect recording consent with tasks | LiveKit Documentation | Improved End-of-Turn Model Cuts Voice AI Interruptions 39%