separate lexicon, rules and test code