def generate_lower_name(model_cls):
    """
    Generates the name of the class from the class object, e.g. ``SomeClass`` -> ``some_class``

    :param model_cls: class to evaluate
    :return: lowercase name
    :rtype: basestring
    """
    return getattr(model_cls, '__mapiname__', model_cls.__tablename__)