some refactoring on conversation module