]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
gguf-py : fix some metadata name extraction edge cases (#8591)
authorcompilade <redacted>
Sun, 21 Jul 2024 01:58:49 +0000 (21:58 -0400)
committerGitHub <redacted>
Sun, 21 Jul 2024 01:58:49 +0000 (21:58 -0400)
commit328884f4219c0228673cf1870ac63987fb4f9fd0
tree7ca2b2fd4eb1e6dd17b48f03aca0e47dff66619e
parentc69c63039cd75f8f33f253ab7485d82a8b4cd403
gguf-py : fix some metadata name extraction edge cases (#8591)

* gguf-py : fix some metadata name extraction edge cases

* convert_lora : use the lora dir for the model card path

* gguf-py : more metadata edge cases fixes

Multiple finetune versions are now joined together,
and the removal of the basename annotation on trailing versions
is more robust.

* gguf-py : add more name metadata extraction tests

* convert_lora : fix default filename

The default filename was previously hardcoded.

* convert_hf : Model.fname_out can no longer be None

* gguf-py : do not use title case for naming convention

Some models use acronyms in lowercase,
which can't be title-cased like other words,
so it's best to simply use the same case
as in the original model name.

Note that the size label still has an uppercased suffix
to make it distinguishable from the context size of a finetune.
convert_hf_to_gguf.py
convert_lora_to_gguf.py
gguf-py/gguf/metadata.py
gguf-py/gguf/utility.py
gguf-py/tests/test_metadata.py