27 lines
719 B
Python
27 lines
719 B
Python
from secret_config import *
|
|
|
|
from hf_gguf_models import (
|
|
ensure_gguf_downloaded,
|
|
list_repo_gguf_files,
|
|
search_gguf_repositories, GGUFRepository,
|
|
)
|
|
from llm_inference import load_llama_model
|
|
|
|
# repos: list[GGUFRepository] = search_gguf_repositories("llama 3.1 8b instruct", limit=5, token=hugging_face_token)
|
|
# for repo in repos:
|
|
# print(repo)
|
|
# print("====")
|
|
# files = list_repo_gguf_files(repos[0].repo_id)
|
|
# for file in files:
|
|
# print(file)
|
|
|
|
selected_repo_id='bartowski/Meta-Llama-3.1-8B-Instruct-GGUF'
|
|
selected_filename='Meta-Llama-3.1-8B-Instruct-Q3_K_XL.gguf'
|
|
|
|
|
|
model_path = ensure_gguf_downloaded(
|
|
repo_id=selected_repo_id,
|
|
filename=selected_filename,
|
|
)
|
|
|
|
print("Model was downloaded") |