Would it be a good idea to extract this `define_model` to a method?