https://retellai.com/?utm_source=discord&utm_medium=seo logo
Call ID - call_4cc73c005b0dd011f987f8dc01d Latency...
# ❓・ai-evy-support
b
Call ID - call_4cc73c005b0dd011f987f8dc01d Latency in Call - 2817ms General latency should be 970-1300ms latency for this agent. @AI Evy - how to control latency?
a
Thanks for tagging me @balat_92645. I'll look through relevant sources and get back to you shortly.
### Answer Based on your call showing 2817ms latency when you expect 970-1300ms, here are the key ways to control latency in Retell AI: ## Agent Configuration Settings Several agent settings directly impact latency and are marked with a turtle icon to indicate they increase latency [(1) ]() : **Responsiveness**: Controls how responsive the agent is, with values from [0,1] [(2) ]() . Higher values mean faster exchanges and quicker responses . **STT Mode**: Set to "fast" mode instead of "accurate" for lower latency :
Copy code
javascript
"stt_mode": "fast"
**Interruption Sensitivity**: Higher values (0-1 range) allow users to interrupt more easily, potentially reducing perceived delays . ## Monitoring and Analysis You can monitor latency metrics in the Call History section [(3) ]() . The system tracks several key metrics : - **P90 (90th Percentile) **: 90% of calls have latency below this value - **Median (50th Percentile) **: Half of calls have latency less than this value - **Min**: The fastest response time achieved End-to-end latency measures the total time from when the user stops speaking until the AI agent begins responding, including processing time, network delays, and model inference time . ## Technical Factors Retell AI achieves latency as low as 600ms through optimized infrastructure [(1) ]() . The platform uses edge computing and predictive response generation to minimize delays [(4) ]() . For your specific case with 2817ms latency, I'd recommend checking your agent's configuration for any settings marked with turtle icons and ensuring STT mode is set to "fast" rather than "accurate" [(1) ]() [(2) ]() .
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
b
How do I setup STTmode? @AI Evy
a
Thanks for the follow-up, @balat_92645. I'll get back to you soon.
### Answer You can set the STT mode (speech-to-text mode) when creating or updating an agent using the
stt_mode
parameter [(1) ]() [(2) ]() [(3) ]() . The
stt_mode
parameter determines whether speech to text should focus on latency or accuracy [(3) ]() . The available options are: - `fast`: optimize for speed mode - `accurate`: optimize for accuracy mode The default is fast mode . ## When Creating an Agent
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
 apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.create({
 response_engine: { llm_id: 'llm_234sdertfsdsfsdf', type: 'retell-llm' },
 voice_id: '11labs-Adrian',
 stt_mode: 'fast'
}) ;
[(1) ]() ## When Updating an Existing Agent
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
 apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.update('16b980523634a6dc504898cda492e939', { 
 agent_name: 'Jarvis',
 stt_mode: 'fast'
}) ;
[(3) ]() ## Choosing Between Modes From benchmarking, both
optimize for speed
mode and
optimize for accuracy
mode have similar WER (Word Error Rate) [(4) ]() . The difference mainly lies in capturing entities like numbers and dates . If your use case relies heavily on capturing these entities well, you should use the
optimize for accuracy
mode . Otherwise you can use the
optimize for speed
mode for best latency . The
optimize for accuracy
mode will incur approximately 200ms additional latency .
​ To learn more, see the sources I considered: [[1] Create Agent](https://docs.retellai.com/api-references/create-agent) [[2] Update Agent](https://docs.retellai.com/api-references/update-agent) [[3] Update Agent](https://docs.retellai.com/api-references/update-agent) [[4] Balance between transcription accuracy and latency](https://docs.retellai.com/build/transcription-mode) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
b
Can I do it on retell console or only via API call? @User
a
Appreciate the feedback! Feel free to ask me again with additional guidance or context.
b
Can I do it on retell console or only via API call? @AI Evy
a
Thanks for the follow-up, @balat_92645. I'll get back to you soon.
### Answer [(1) ]() [(2) ]() [(3) ]()
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
 apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.create({
 response_engine: { llm_id: 'llm_234sdertfsdsfsdf', type: 'retell-llm' },
 voice_id: '11labs-Adrian',
}) ;
[(1) ]()
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
 apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.update('16b980523634a6dc504898cda492e939', { 
 agent_name: 'Jarvis'
}) ;
[(2) ]() [(3) ]() Based on the available documentation, I can only find information about configuring STT mode through the API endpoints for creating and updating agents [(1) ]() [(2) ]() [(3) ]() . The sources don't provide information about whether this setting is available through the Retell console interface. I don't have specific documentation about console interface availability for STT mode configuration. You might want to check the Retell dashboard directly or contact support for clarification on console interface options. Would you like me to provide a general answer based on my knowledge instead?
​ To learn more, see the sources I considered: [[1] Create Agent](https://docs.retellai.com/api-references/create-agent) [[2] Update Agent](https://docs.retellai.com/api-references/update-agent) [[3] Update Agent](https://docs.retellai.com/api-references/update-agent) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.