misc
refactoring chat/