Refactor the project. Phase 4: NaiveBayes classifier