Defining Models in Python