Supervised fine-tuning and Reinforcement Learning from Human Feedback (RLHF) can reduce the output diversity of language models