Some refactoring fo the beer and drug classifier.