import re

name = "John"

input_sense_auxs = [
    "These sound system are too many, I think John can help us, otherwise it will be waiting for a while longer",
    "These sound system are too many but I know that John can help us, otherwise it will be waiting for a while longer",
    "These sound system are too many but I know that John can help us. otherwise it will be waiting for a while longer",
    "Do you know if John with the others could come this afternoon?",

    "John can help us, otherwise it will be waiting for a while longer",
    "Can you help us, otherwise it will be waiting for a while longer for John",
    "sorry! can you help us? otherwise it will be waiting for a while longer for John"]

regex_patron_m1 = fr'(?:^|[?!¿¡,;:([.])\s*(?:(\w+(?:\s+\w+)*)\s*)?{name}(?:\s*(\w+(?:\s+\w+)*))?\s*(?:$|[]?!,;:).])'
# r"\s*((?:\w\s*)+)\s*?" + name + r"\s*((?:\w\s*)+)\s*\??"
for input_sense_aux in input_sense_auxs:
    print(f'--- {input_sense_aux} ---')
    m1 = re.search(regex_patron_m1, input_sense_aux, re.IGNORECASE) #Con esto valido la regex haber si entra o no en el bloque de code
    if m1:
        something_1, something_2 = m1.groups()

        something_1 = something_1.strip() if something_1 else ""
        something_2 = something_2.strip() if something_2 else ""

        print(repr(something_1))
        print(repr(something_2))