fixing is_match logic for treebank files