See https://github.com/ethanyanjiali/minChatGPT for more details. I only used HF to store the weights.