very very nitpicky, but i'd perhaps name the generating expression `category_generator` or something like that, just in case someone thinks we're writing a flatline filter here...