rewrite category