def slugify(value, allow_dots=False, allow_unicode=False):
    if allow_dots:
        pattern = _re_pattern_allow_dots
    else:
        pattern = _re_pattern

    value = force_text(value)
    if allow_unicode:
        value = unicodedata.normalize('NFKC', value)
        value = pattern.sub('', value).strip().lower()
        return _re_spaces.sub('-', value)
    value = unicodedata.normalize('NFKD', value).encode('ascii', 'ignore').decode('ascii')
    value = pattern.sub('', value).strip().lower()
    return _re_spaces.sub('-', value)
Converts to lowercase, removes non-word characters (alphanumerics and
dataset/ETHPy150Open joke2k/faker/faker/utils/text.py/slugify