Refactor listeners into their own module.  Extract sample rules.txt from code and put it into the package.