def _check_whether_chunk_is_new_section(hit): ''' a checker to validate whether a given piece of context could conceivably be a real litigation mention and not just some detritus picked up by the regexes from the table of contents or something ''' # check to see whether it belongs to the table of contents for token in nltk.word_tokenize(hit): if re.match(LPRC.common_words_in_legitimate_legal_proceeding_hits(), token): return True return False