How to Effectively Use Topic Models for Software Engineering Tasks? An Approach based on Genetic Algorithms