from huggingface_hub import HfApi, HfFolder, Repository | |
# Define your repo ID and local path | |
repo_id = "nvl-og/llama3-chatbot" | |
local_dir = "/home/nvl/Llama3-ChatQA-1.5-8B" | |
# Create a repository instance | |
repo = Repository(local_dir=local_dir, clone_from=repo_id) | |
# Add files and commit | |
repo.git_add(auto_lfs_track=True) | |
repo.git_commit("Initial commit of my model") | |
# Push to Hugging Face Hub | |
repo.git_push() | |