from transformers import AutoModel checkpoint = "meta-llama/Llama-2-7b" model = AutoModel.from_pretrained(checkpoint)