from huggingface_hub import Repository # Hugging Face 仓库的 URL (替换为你的实际仓库地址) repo_url = "https://huggingface.co/GooooGLE/testVulModel" # 需要上传的本地仓库路径 local_repo_path = "./" # 克隆 Hugging Face 仓库到本地路径 repo = Repository(local_dir=local_repo_path, clone_from=repo_url) # 推送所有本地更改到 Hugging Face 仓库(包括大文件) repo.git_add(auto_lfs_track=True) # 自动添加大文件到LFS repo.git_commit("Upload entire repository with large files") repo.git_push()