Code smells are symptoms of poor design choices. Previous studies assessed the impact of smells on bug-proneness of classes. In this paper, we build a specialized bug prediction model for smelly classes. We evaluate the contribution of a measure of the severity of code smells by adding it to existing models based on both product and process metrics, and comparing the results of the new model against the baseline ones. Results indicate that the accuracy of a bug prediction model increases by adding the code smell intensity as predictor. We also compare our results with the ones of an alternative technique which considers historical metrics of code smells, finding that our model works better. By evaluating the information gain provided by the...