def METHOD_NAME(cls, **kwargs):
    """Get or create a database object.
    Returns:
        A model instance.
    """
    instance = cls.query.filter_by(**kwargs).first()
    if not instance:
        instance = cls(**kwargs)
        db_session.add(instance)
        db_session.commit()
    return instance