Exemple #1
0
def split_year(txt: str) -> List[str]:
    r = [x for x in re.split(r'((?:19|20)\d{2})r*', txt) if len(x) > 1]
    return shapers.pairs(r)
Exemple #2
0
def split_nr(txt: str) -> List[str]:
    r = [x for x in re.split(r'Nr(\d*)', txt) if len(x) and x != ',']
    return shapers.pairs(r)
def krnnt(text):
    response = requests.post('http://localhost:9200', text.encode("utf-8")) \
            .content.decode("utf-8") \
            .split("\n")
    return list(
        map(tuple_split, filter(twos, map(split, shapers.pairs(response)))))[0]