How to design rules and how to organize them