gguf-collections / References /upload_to_hf.py
rajivmehtapy's picture
Upload folder using huggingface_hub
697548f verified
raw
history blame contribute delete
420 Bytes
from huggingface_hub import HfApi
api = HfApi()
model_id = "rajivmehtapy/gguf-collections"
api.create_repo(model_id, exist_ok=True, repo_type="model")
api.upload_file(
path_or_fileobj="AutoCoder_S_6.gguf",
path_in_repo="AutoCoder_S_6.gguf",
repo_id=model_id,
)
# uncomment to upload folder
# api.upload_folder(
# repo_id=model_id,
# folder_path="./References",
# path_in_repo="/References",
# )