added type parameters to model generator