chat and chat messages model