Implemented basic text mining method in the controller