Skip to main content

Answering Machine Detection

  • How do I tune the machine detection logic?

    You can use the following parameters to tune the machine detection based on your use case. For more details, please refer to our API documentation.

     

    Parameter Description

    machine_detection_maximum_speech_length

    (optional)

    The number of milliseconds used to measure the length of speech activity. Note that machine_detection_maximum_speech_length must be a positive integer. 


    Durations greater than this value will be detected as a machine.


    Default: 5000 

    Allowed values: Between 1000 to 6000

    machine_detection_initial_silence

    (optional)

    The duration of initial silence when the call is answered, expressed in milliseconds. Note that machine_detection_initial_silence must be a positive integer.


    “Unknown” will be returned after the specified value. 


    Default: 4500 

    Allowed values: Between 2000 to 10000

    Machine_detection_maximum_words
    (optional)

    The maximum number of sentences detected. Machine_detection_maximum_words must be a positive integer. 


    Values greater than the threshold you set will be classified as a machine.


    Default: 3 

    Allowed values: Between 2 to 10

    Machine_detection_initial_greeting
    (optional)

    Indicates the maximum length of the initial greeting in milliseconds. machine_detection_initial_greeting must be a positive integer.


    Duration longer than this value will be detected as a machine.


    Default: 1500 

    Allowed values: Between 1000 to 5000 

    Machine_detection_silence
    (optional)

    The silence after the initial greeting, expressed in milliseconds. Machine_detection_silence must be a positive integer. 


    Durations greater than this value will be detected as a human.


    Default: 800

    Allowed values: Between 500 to 5000

  • How accurate is answering machine detection? What can I do to increase its accuracy?

    We detect voicemail using heuristic algorithms that are based on tone of voice, the speed of spoken words, and other factors. This detection usually takes three to five seconds with an accuracy of 60-75%, which is on par with industry standards. 

    You can enable answering machine detection (AMD) using our Call object with the machine_detection and machine_detection_time parameters.

    To increase AMD accuracy, use asynchronous machine detection and increase the wait time using the machine_detection_time attribute, which specifies the time allotted in milliseconds to decide whether the connection is with a machine. The default value is 5,000. You can specify an integer value between 2,000 and 10,000.

  • How do I change the call flow once a call is answered by a machine?

    The machine_detection parameter in the outbound call object can tell you when a call is answered by a machine.

    To change the call flow when a machine is detected

    Set the machine_detection argument of the Call method to “true.” If a machine is detected during the call and machine_detection is set to true, Plivo makes a request to any URL invoked by the call (such as answer_url or hangup_url), and in the request the machine parameter is set to true.

    To hang up a call when a machine is detected

    Set the machine_detection argument of the Call method to “hangup.” If a machine is detected during the call and machine_detection is set to hangup, Plivo hangs up the call immediately and makes a request to the URL specified in the hangup_url attribute, and in the request the machine parameter is set to true.

  • What's the difference between synchronous and asynchronous machine detection?

    You can use either synchronous or asynchronous machine detection on a call.

    Synchronous machine detection

    Synchronous machine detection is effective when you're more than 50% sure that a machine is answering the call. When the Call object's machine_detection attribute is set to either "true" or "hangup" and the machine_detection_url is not defined, Plivo uses synchronous machine detection. 

    Asynchronous machine detection

    Asynchronous machine detection is effective when you're not sure if a machine or a human is answering the call. When the Call object's machine_detection attribute is set to "true" and the machine_detection_url is defined with a different call flow (for instance, to trigger a call transfer), Plivo uses asynchronous machine detection. 

  • What different types of machine detection does Plivo support?

    We support two types of machine detection: synchronous and asynchronous.

    Synchronous machine detection  

    If the machine_detection parameter is set to "true" and a machine is detected at the beginning of the call, Plivo will POST the URL that's invoked by the call (answer_url or hangup_url) with the machine_detection parameter set to "true."

    If you want to change the call flow based on machine detection status, you can specify a condition. For example, if the machine_detection parameter is posted as “true” in the answer_url then another set of XML will be fetched which will change the call flow.

    If you want to hang up the call when a machine is detected, set the machine_detection parameter to "hangup." The call will be hung up and the API will POST the machine_detection attribute set as "true" to the hangup_url.

    If the machine_detection_url is not defined in the outbound call API, Plivo will use synchronous machine detection.

    Asynchronous machine detection

    With asynchronous machine detection, detection takes place in the background. The call flow can be changed as soon as the machine is detected.

    To use this method, set the machine_detection_url parameter when firing the outbound call API. Plivo will detect a machine in the background and invoke the machine_detection_url with parameters to take the desired action.

    When machine_detection is set to "true" and the machine_detection_url is defined with a different call flow (for example to trigger a transfer a call API) in the outbound call API, Plivo will use asynchronous machine detection.

    Read more about machine detection in our documentation.

  • Can I find out whether a call was answered by a machine or a human?

    The machine_detection parameter in the outbound call object can tell you whether a call was answered by a machine or a human. See our documentation on answering machine detection.

  • Getting started with answering machine detection

    Rather than detecting voicemail by listening for a beep, Plivo by default detects voicemail using heuristic algorithms that are based on tone of voice, the speed of spoken words, and other factors. This detection usually takes three to five seconds with an accuracy of 60-75%, which is on par with industry standards. You can enable answering machine detection (AMD) using our Call object with the machine_detection and machine_detection_time parameters. See our documentation on answering machine detection.