Closed moshekr closed 6 years ago
+1
Hi @moshekr , I will check the technical specs of dialogflow v2 and give you a road map the next days.
+1
+1
+1
Hey @spoeck any update ? :) Thanks for the useful work again! 🎉
Update: I'm working on support for v2. I will release a beta next week!
Update:
For the REST calls for V2 I would need some help. Can someone give me a example REST POST? I don't understand the URL param ({session=projects//agent/sessions/})
have you check this part? (check the cURL example) https://dialogflow.com/docs/reference/v2-auth-setup
I'm not totally sure on the v2 POST on the URL parameters.
Thanks @eggybot for the auth setup link! requests with speech/text/events are working (see in the example app on android)
The link is something like this: https://dialogflow.googleapis.com/v2beta1/projects/testv2-3b5ca/agent/sessions/0:detectIntent
BUT: Contexts are NOT working. And I think there is a new mechanism. In V1 you just put the contexts into the request and everything fine. But in V2, do I have to create the contexts separatly before making a text request? Does anyone know how to use the context endpoint? https://dialogflow.com/docs/reference/api-v2/rest/v2beta1/projects.agent.sessions.contexts/create
I compare v1 and v2, I'm not sure if I'm correct but it looks the same but it has different session approach.
You can try and check here https://cloud.google.com/dialogflow-enterprise/docs/migrating and go to context and try the Context create here https://cloud.google.com/dialogflow-enterprise/docs/reference/rest/v2beta1/projects.agent.sessions.contexts/create it has a test/explorer tool (on the right side) and it might give you much better explanation on the result
Ah damn !!! now I got it
When you wan't to set a context for example deals
, instead of setting:
{
"name": "deals",
"lifespan": 1
}
in V2 you have to set
{
"name": "projects/testv2-3b5ca/agent/sessions/0/contexts/deals",
"lifespanCount": 1
}
so I will concat the path of the name in background so that you can set the context in V2 as below:
{
"name": "deals",
"lifespanCount": 1
}
Published v3.0.0 with Dialog-V2 support!
Thanks!
@spoeck : You mentioned about context being reset, and thats what I get when trying your sample on a flow that has a followup intent. The base intent seems to be working fine but when i speak into the app for the followup, it seems to not take the original context. Do we need to manually setup the contexts ?
@rajasaur
can you show us your code? also do you have the Dialogflow.resetContexts
somewhere in your code? that code will reset the context.
@eggybot , Its the same in the sample (https://github.com/innFactory/react-native-dialogflow/tree/master/example). Tried to use it against one of my simple projects which only has 2 intents -- main and a followup. The main intent got recognized properly but the followup dint.
@rajasaur can you check the lifespan of your context in dialogflow, as well try to chat or speech chat directly on dialogflow test section (right side of intent). Then let me know if it works or not.
Hey, any plan to support dialogflow v2? in particular the streaming option