Skip to content

Commit

Permalink
minor changes to intent schema
Browse files Browse the repository at this point in the history
  • Loading branch information
anjishnu committed Mar 27, 2016
1 parent 4b291b9 commit 9ee1136
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions ask/intent_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,17 @@ class IntentSchema(object):
'''
def __init__(self, json_obj=None):
if json_obj:
# Use existing intent schema
self._obj = json_obj
else:
# Create one from scratch
self._obj = OrderedDict({ "intents" : [] })

# These intents are basically always needed
# for certification
self.add_intent('AMAZON.HelpIntent')
self.add_intent('AMAZON.StopIntent')
self.add_intent('AMAZON.CancelIntent')

def add_intent(self,intent_name, slots=None):
if not slots: slots = []
Expand Down

0 comments on commit 9ee1136

Please sign in to comment.