medmekk/BitNet.cpp
18
1from transformers import AutoModel, AutoTokenizer2import os3from huggingface_hub import HfApi4api = HfApi()5 6# Specify the model name and the directory where you want to save it7MODEL_NAME = "TinyLlama/TinyLlama-1.1B-Chat-v1.0" # Example model name8save_directory = "./tinyllama" # Specify your folder path here9 10# Download the model and tokenizer11model = AutoModel.from_pretrained(MODEL_NAME)12tokenizer = AutoTokenizer.from_pretrained(MODEL_NAME)13 14# Save the model and tokenizer to the specified directory15 16repo_id = "medmekk/BitNet.cpp"17 18api.upload_folder(19 folder_path="models/tinyllama",20 repo_id="medmekk/BitNet.cpp",21 repo_type="space",22)23 