def match_punctuation(string): return match(punctuation_regex, string)
def words(sentence): tagged_sentence = tag(sentence) tagged_words = filter(lambda tu: match(word_tag_re, second(tu)), tagged_sentence) ws = map(first, tagged_words) return list(ws)