znorris / alexa-flask-FSM

An example of using flask, flask-ask, and transitions to handle conversations with Alexa.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Flask-ask with State Machine for use in Alexa Skills

After using dgtony's AFG for scenario-based dialogues I became more interested in using a state machine for managing conversation state. In this example I use the python library transitions to handle all the heavy lifting.

Example Model

This is the model used in the example. Such diagrams can be made by the machine itself: Kiku

##Benefits:

  1. It is much simpler to reason about the conversational flow when using a state machine.

  2. Most state machine libraries have a logging ability. This will be incredibly useful for keeping track of how users interact with your skill.

Feel free to create issues if you have questions or comments!

About

An example of using flask, flask-ask, and transitions to handle conversations with Alexa.


Languages

Language:Jupyter Notebook 98.1%Language:Python 1.9%