What is The Secret to Faster LLM Inference

Whenever I use an AI chat tool, I always wonder: how does it generate text so quickly?