diff --git a/examples/json_schema_pydantic_example.py b/examples/json_schema_pydantic_example.py index 2a24f8118..c7ca7b8d9 100644 --- a/examples/json_schema_pydantic_example.py +++ b/examples/json_schema_pydantic_example.py @@ -1,7 +1,7 @@ # Usage: #! ./llama-server -m some-model.gguf & #! pip install pydantic -#! python json-schema-pydantic-example.py +#! python json_schema_pydantic_example.py from pydantic import BaseModel, Extra, TypeAdapter from annotated_types import MinLen diff --git a/gguf-py/scripts/__init__.py b/gguf-py/scripts/__init__.py index 1ad45639a..f9d29cb69 100644 --- a/gguf-py/scripts/__init__.py +++ b/gguf-py/scripts/__init__.py @@ -1,13 +1,4 @@ -import os - -from importlib import import_module - - -os.environ["NO_LOCAL_GGUF"] = "TRUE" - -gguf_convert_endian_entrypoint = import_module("scripts.gguf-convert-endian").main -gguf_dump_entrypoint = import_module("scripts.gguf-dump").main -gguf_set_metadata_entrypoint = import_module("scripts.gguf-set-metadata").main -gguf_new_metadata_entrypoint = import_module("scripts.gguf-new-metadata").main - -del import_module, os +from .gguf_convert_endian import main as gguf_convert_endian_entrypoint +from .gguf_dump import main as gguf_dump_entrypoint +from .gguf_set_metadata import main as gguf_set_metadata_entrypoint +from .gguf_new_metadata import main as gguf_new_metadata_entrypoint diff --git a/scripts/check-requirements.sh b/scripts/check-requirements.sh index 27f264999..48f924c02 100755 --- a/scripts/check-requirements.sh +++ b/scripts/check-requirements.sh @@ -97,7 +97,7 @@ check_requirements() { } check_convert_script() { - local py=$1 # e.g. convert_hf_to_gguf.py + local py=$1 # e.g. ./convert_hf_to_gguf.py local pyname=${py##*/} # e.g. convert_hf_to_gguf.py pyname=${pyname%.py} # e.g. convert_hf_to_gguf