remove irrelevant clauses