Construct a callable object and a string sufficient to reconstruct it later (unpickling)

    >>> make_named_stemmer('str_lower')
    ('str_lower', <function str_lower at ...>)
    >>> make_named_stemmer('Lancaster')
    ('lancaster', <Stemmer object at ...>)

def make_named_stemmer(stem=None, min_len=3):
    """Construct a callable object and a string sufficient to reconstruct it later (unpickling)

    >>> make_named_stemmer('str_lower')
    ('str_lower', <function str_lower at ...>)
    >>> make_named_stemmer('Lancaster')
    ('lancaster', <Stemmer object at ...>)
    """
    name, stem = stringify(stem), make_stemmer(stem=stem, min_len=min_len)
    if hasattr(stem, '__name__'):
        return stem.__name__, stem
    if name.strip().lower() in STEMMER_TYPES:
        return name.strip().lower(), stem
    if hasattr(stem, 'pattern'):
        return stem.pattern, stem
    return stringify(stem), stem