Overview
Voice formatting automatically transforms raw text from your language model into a format that sounds natural when spoken by text-to-speech technology. This feature helps your agents communicate more effectively by converting technical text into conversational speech patterns. Voice formatting enables your agents to naturally speak:- Numbers and currency (e.g., $42.50→ “forty two dollars and fifty cents”)
- Phone numbers (e.g., +1234567890→ “plus one two three four five six seven eight nine zero”)
- Dates, times, and percentages in conversational format. (Currenly this is limited to dates in the format dd/mm/yyyyordd-mm-yyyyoryyyy-mm-ddoryyyy/mm/dd) (e.g.,10/05/2023→ “May 10th, 2023”)
How Voice Formatting Works
When enabled, voice formatting processes your agent’s text output through a series of transformations. Each transformation targets specific patterns to make speech sound more natural and conversational.Formatting Transformations
The formatting system applies these transformations in order:| Step | Function | Description | Before | After | 
|---|---|---|---|---|
| 1 | Format currency | Converts dollar amounts to spoken words | $42.50 | forty two dollars and fifty cents | 
| 2 | Format emails | Replaces @with “at” and.with “dot” | john@example.com | john at example dot com | 
| 3 | Format dates | Converts dates into spoken format | 10-05-2023 | May tenth, two thousand twenty three | 
| 4 | Format times | Time expressions | 2:00 PM | two PM | 
| 5 | Format distances | Converts distance measurements | 5km | 5 kilometers | 
| 6 | Format units | Converts measurement units | 100g | 100 grams | 
| 7 | Format percentages | Converts percentage symbols | 50% | 50 percent | 
| 8 | Format phone numbers | Spaces out digits for clarity | +1234567890 | plus one two three four five six seven eight nine zero | 
| 9 | Remove markdown | Removes markdown symbols like _,`, and~ | **Bold** and *italic* | Bold and italic | 
| 10 | Format new lines | Converts line breaks to periods for smoother speech | Hello world \nto say | Hello world . to say | 
| 11 | Format colons | Replaces :with.for better phrasing | price: $42.50 | price. forty two dollars and fifty cents | 
| 12 | Handle special characters | Speaks special characters like /and_ | 5/207 | five slash two hundred and seven | 
| 13 | Format numbers | Handles general numbers appropriately | -9, 2.5, 2023 | minus nine, two point five, two thousand twenty three | 
Enabling Voice Formatting
Voice formatting is controlled through your agent settings:In Agent Settings
- Navigate to your Agent Settings
- Go to the Advanced Settings tab
- Find the Voice Formatting toggle
- Enable the feature to activate natural speech formatting
When to Use Voice Formatting
Enable voice formatting when:- Your agent handles customer service calls
- You need natural-sounding currency and number pronunciation
- Your agent reads addresses, phone numbers, or dates
- Professional, conversational tone is important
- Your agent primarily handles technical support requiring precise terminology
- You need exact control over pronunciation
- Your use case involves specialized vocabulary that formatting might alter
Best Practices
Content Writing
- Write naturally in your prompts—let formatting handle the technical conversion
- Use standard formats for dates, currency, and numbers.
- Dates should be in the format dd/mm/yyyyordd-mm-yyyyoryyyy-mm-ddoryyyy/mm/dd
- Currency should be in the format $100or100 USD
- Numbers should be in the format 100or100.00
- Phone numbers should be in the format +1234567890
- Percentages should be in the format 50%
- Distances should be in the format 5km
- Units should be in the format 100g
- Emails should be in the format john@example.com
 
- Dates should be in the format 
- Test your agent’s speech output after enabling formatting
- Do not mention any specific formatting for numbers, dates, currency, phone numbers, percentages, distances, units, emails, etc. in your agent’s prompts as it may clash with the voice formatting system.
- In case some numbers are not being formatted correctly, you can use --to separate the numbers into groups of digits you want to be formatted. For example: Pin code is123456can be written as1--2--3--4--5--6to make the Agent speak the numbers slowly.
Testing
- Enable voice formatting in a test environment first
- Listen to how your agent pronounces different types of content
- Adjust your content strategy based on formatting results