import re


def get_cough_type(cough_path: str) -> str:
    """Returns cough type {`cough_1`, `cough_2`, `cough_3`} from audio path
	Note: this function is specific to wiai-facility/ dataset.
    """

    # defines regex pattern: example - cough_[integer in 0-9].wav
    pattern = r'cough_[\d]\.wav'
    # finds all matches of the above pattern in cough_path
    # assuming there is only 1 occurence of cough_*.wav
    find = re.findall(pattern, cough_path)[0]
    cough_type = find.split('.')[0]

    return cough_type