updated the model moving to sqlalchemy from peewee