working generator for filter rules