Default skill and intent handling #7
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I have tweaked the default handling of intents a bit:
As a smaller change, Peeqo looks up the responseText from Dialogflow (or the response from any other intent engine) or the intent name on Giphy if no intent has been defined in dialogflow-intents.js. While playing with Peeqo this has been one of the most important changes I've made so far because it allows me to add many new intents on Dialogflow without having to touch Peeqo's code.
I also propose a new skill structure which allows to add new intents in a more modular way without having to change dialogflow-intents.js. This makes it easier to fetch future updates from the Git rep without having to re-write existing skills/intents. It should also allow people to add new intents or skills which are compatible with future intent engines. Furthermore, it would be easier to download standalone skills or intents and simply copy them into one directory without having to touch any other code.
As a demo I have added a new datetime skill which displays the current date and time.