LLM Laboratory

Date: 18.08.2025

TensorFlow-friendly causal LMs in 🤗 Transformers 4.x

This table lists decoder-only (causal LM) model families that have TensorFlow classes in Transformers 4.x and publish TensorFlow weights (tf_model.h5) on the Hugging Face Hub.
If tf_model.h5 is present for the checkpoint, you can load with TFAutoModelForCausalLM.from_pretrained(...) without converting from PyTorch.

Model family Hugging Face repo TF weights present? (Conversion needed?)
OpenAI GPT (GPT‑1) openai-community/openai-gpt Yestf_model.h5 available → No conversion needed
GPT‑2 (family) openai-community/gpt2 Yestf_model.h5 available → No conversion needed
DistilGPT‑2 distilbert/distilgpt2 Yestf_model.h5 available → No conversion needed
DialoGPT (GPT‑2 based) microsoft/DialoGPT-medium Yestf_model.h5 available → No conversion needed
CTRL Salesforce/ctrl Yestf_model.h5 available → No conversion needed
Transformer‑XL transfo-xl/transfo-xl-wt103 Yestf_model.h5 available → No conversion needed
XLNet xlnet/xlnet-base-cased Yestf_model.h5 available → No conversion needed
XLM (CLM variant) FacebookAI/xlm-clm-ende-1024 Yestf_model.h5 available → No conversion needed
OPT (small) facebook/opt-125m Yestf_model.h5 available → No conversion needed
OPT (2.7B) facebook/opt-2.7b Yestf_model.h5 available → No conversion needed
GPT‑J‑6B EleutherAI/gpt-j-6b Yestf_model.h5 available → No conversion needed

Notes