Rename this to `name` and at the bottom add `__table_args__ = (db.UniqueConstraint(profile_id, name),)`