Moved code to Google App Engine. Added ndb usage for prefs. Currently not in prod.