Keep the data and conversation object in the conversation context
Closed this issue · 2 comments
Is your feature request related to a problem? Please describe.
the data and conversation object keep the state of some Actions resources. We should keep them
Describe the solution you'd like
Review some requests with @jperata to validate what kind of information should be sent. (I have some request and responses that can not be shared in public)
Describe alternatives you've considered
Use our current context maintenance, but is insufficient
Folks, we need this. You can't really test anything beyond "hello" without it. So it's not useful to us at all if we have to build our own Google responses ourselves for anything other than Welcome intent commands. Today I'm going to drill down into the payload Google sends to our fulfillment servers when non-welcome actions are taken. And then I can just maintain the conversation context myself.
@dcoli we have reviewed both the specifications for Dialog Flow both for V1 (which is going to be deprecated next October) and for V2, we preserve the context correctly on both cases. Reviewing your request and responses again has the output context from V2 coming in the responses (probably because you are using the latest version of the dialog flow libraries), but has the requests being generated in the V1 format. This happens when we detect that the interaction model imported from DialogFlow is a V1. (We have been using this as reference https://dialogflow.com/docs/reference/v1-v2-migration-guide-fulfillment to check the difference between formats)
Please ensure your model and your code are in the same Version of dialog flow, this should preserve the context correctly which is the one that keeps the "query" parameter you need.
The "data" attribute or "payload" in the V2 model should not affect the next request at all apart from the info that is inside the context attributes. If you still need to pass data from one request to another use the filter property and you can do:
const context = response.property;
vga.addFilter((request) => {
request.otherProperty = context;
});