Compare the pretraining objectives and architectural differences between GPT and BERT. Explain in detail: (1) what pretraining task each model uses (causal language modeling / next-token prediction for GPT vs. masked language modeling + next sentence prediction for BERT),…