The two phases of answering. Prefill processes everything you sent, all at once and in parallel. Decode produces the reply one token at a time. They have completely different performance characteristics, which is why a long prompt with a short answer behaves so differently from a short prompt with a long answer.
Technical view
Prefill is compute-bound and parallelisable across the whole input, dominating time to first token and scaling with prompt length. Decode is memory-bandwidth-bound and inherently sequential, dominating total latency for long outputs. Serving systems often schedule the two separately, and disaggregated architectures place them on different hardware, since the optimal configuration for each is different.
Related
Part of AI Terminology Index, section: Language Models Specifically.