-
-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Handle custom JSON responses in intents #8
Comments
I already use this in my code and solved it this way with the event mqtt topic. In dialgoflow i have the a custompayload
In
Then in the index.js on the ari-bridge i added a subscribe on the mqtttopic in the main() function
Then in the client.on('StasisStart'.....
Most likely not the best way to do it but it handles the job. |
yeah, its a difficult thing because each ARI app is different, and this isn't designed to be a complete solution - just a base for people to work from..... but the mqtt event topic makes sense, I can add in the basics for people to expand upon |
Yeah i know the ari client is still not complete for me aswell. |
Another thing to keep in mind is that the event mqtt handler which detects the custom payload is received up front. This means that when i play audio back from dialogflow like "Please wait while we connect you to an operator" this audio is cut and terminated as the ari bridge is already processing the custom command. I was playing around with an extra mqtt topic to handle the rtp stream if it was live or not. This was intended for the other issue but now make sense to use here. Unless someone has another idea? |
yeah @JorgMuskens it makes sense, or to only give back the result of the intent/custom response to the other app once the audio has finished playing back |
But then again.... if the audio is long, you want to give say an agent being given these transcripts/intent results sooner than after an audio prompt has finished playing. so yeah, probably an audioEnded event |
@JorgMuskens also, I just pushed a new branch on each repo up - both called new functionality - designed to deal with no audio responses better, sending the mqtt events back to the ARI bridge so it can do more decision making etc |
@danjenkins i will test this today and let you know |
Thanks! Theyre both merged in now |
Something broke big time.
|
It looks like there is no open connection between ari and rtp anymore. Is it still working on your end? |
yeah I tested it all with a couple of different scenarios..... I guess I'll go re-do that testing :S |
Crap, I can reproduce :( looking into it now :) |
Based on custom JSON responses in intents generically
![Screen Shot 2020-03-15 at 20 50 57](https://user-images.githubusercontent.com/243117/76710415-447da500-66ff-11ea-9889-fc46f5104f4a.png)
The text was updated successfully, but these errors were encountered: