Can you try to use the backend block? As long as you have the recording file path, send it as a property to the backend block, if the file path is accessible through your application server hosting the voice app, you'll be able to write Java code to read your audio file. I'm not sure what your ASR HTTP endpoint is expecting the audio to be received, is it byte stream/array? If yes you can use Java HTTP methods after reading the file to send it to the ASR.
Let me know how it will be going here.
Original Message:
Sent: 08-25-2023 08:06
From: Julen Iraceburu
Subject: Error with the use of the recordutterance property, when obtaining the audio
Hi Marko, thank you for your interest. I'll try to explain here our scenario, the different solutions that exist and the problems related to each solution.
Scenario: What do I do with the recordings?
My goal is to use a third party service to process the audio and get some results. To achieve this I need to make an HTTP request at a specific step of the IVR callflow, send the caller string and an audio file with the customer's voice from a part of the call, send them to the third party service, and process the response to continue my callflow in a way or another.
Solutions: How can I extract the audio and send it to a service via HTTP for processing?
Solution 1: Use record block
The first option is to use the record block. This solution allows me to record a part of the call with customer voice and store it in a VXML variable. Using an HTTP request I am able to send it to the third party service and process it. This option does not work for me because according to Gensys Engage documentation:
"VoiceXML 2.1 extends these elements so that the Interpreter can conditionally enable recording while simultaneously gathering input from the user. Support for utterance recordingsin the <transfer> and <record> element is optional with VoiceXML 2.1, and is not supported by GVP."
Also, there is a problem with the generation of the VXML code using record block and I have to edit generated code manually to make it work.
Solution 2: Use recordutterance property
The second option is to use the recordutterance property. As I explained in this thread, I managed to save the audio, but the system does not fill the variables with the content of the audio to be able to send it to the third party service to be processed. That is why I ask for help to know if there is something I have done wrong to solve my problem in this way. This solution fits to me because recording is enabled while audio is gathered from user. Also, is a solution compatible with VoiceXML 2.1 (See section 7).
According to GVP8.1 Reference Manual, "Recording User Utterances While Attempting Recognition" section explains how described approach is possible but we can't make it work.
Regarding this solution, I have following questions:
- Why I'm having a "Fetch error retrieving audio" error?
- It's necessary to start any additional service within GVP?
- Is there any other additional configuration required to achieve this?
Solution 3: Use FullCallRecording (FCR)
The third solution is to use StartFCR/EndFCR block to record the audio, as proposed by Erik Norheim. This option records user utterance while gathering audio from user and stores it as an audio file. However, this solution does not provide a VXML variable that holds the audio (as solution 1 and 2 do) so we are not be able to send it via HTTP to the third party service.
We can see how audio file is being stored in callrec folder, however we can't read this file in order to send audio to 3rd party service.
Regarding this solution, I have following questions:
- How can access stored audio file path to send it via HTTP request in the callflow?
- @Erik, could you give us more detail about your script solution? Why do you use a batch script instead of copying the file on-the-fly?
This is our scenario and our current possible solutions. As you see, we're having problems with all of them. Any help would be appreciated.
Thanks for your time.
------------------------------
Julen Iraceburu
Veridas Digital Authentication Solutions SL
Original Message:
Sent: 08-23-2023 02:28
From: Marko Konieczny
Subject: Error with the use of the recordutterance property, when obtaining the audio
Hi Julen,
Is it possible that you explain here how the configurations is done to establish that the system does the recordings.
And are the recordings the whole conversations between customer and agent or is it only the IVR part of the call.
And can you tell what you are doing with the recording?
Thanks in advanced.
With kind regards Marko
------------------------------
Marko Konieczny
ACHMEA INTERNE DIENSTEN N.V.
Original Message:
Sent: 08-10-2023 08:18
From: Julen Iraceburu
Subject: Error with the use of the recordutterance property, when obtaining the audio
I'm trying to run an IVR stream within the genesys engage environment where I want to record the audio sent to the ASR server so it can be used later. To do this use the VXML property "recordutterance":
<property name="recordutterance" value="true"/>
The following parameter was set within the IVR profile:
gvp.service-parameters/voicexml.gvpi.$asrwavfilelog$
You can see how the audio is being saved in the following path:
C:\ProgramData\Nuance\Enterprise\Environment
However, when the VXML tries to access the audio after recording, the variable where the audio should be collected (application.lastresult$.recording) is set to "undefined".
The session execution logs show an error when calling a service to get the audio:
error:
FMThreadQueue.cxx:779 Request failed: uri=http://DEMOSRV:8000/, result= 7
Fetch error retrieving audio http://DEMOSRV:8000/ error on url http://DEMOSRV: 8000/Environment/callLogs/TestRecordutterance/2023/08August/07/03/NUAN-29-08-DEMOSRV-GENAMHHEAAAEEPIBAAAAAAAAB-utt001-SAVEWAVEFORM.wav, reason Unable to fetch content, callid 0184024D-10007020
Is it possible that some additional service needs to be lifted?
Do I need to configure anything on the ASR server to enable audio recording?
Is this the correct way to make a recording with the "recordutterance" property?
Tks.
#SIP/VolP
------------------------------
Julen Iraceburu
------------------------------