Skip to content

Commit e311e7d

Browse files
MollySophiaCISC
andauthored
Update convert_hf_to_gguf.py
Co-authored-by: Sigbjørn Skjæret <[email protected]>
1 parent 867aa85 commit e311e7d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

convert_hf_to_gguf.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1083,8 +1083,8 @@ def _set_vocab_rwkv_world(self):
10831083
self.gguf_writer.add_token_types(toktypes)
10841084
special_vocab = gguf.SpecialVocab(self.dir_model, load_merges=False)
10851085
if special_vocab.chat_template is None:
1086-
template_path = Path(sys.path[0]) / "models" / "templates" / "llama-cpp-rwkv-world.jinja"
1087-
if template_path.exists():
1086+
template_path = Path(__file__).parent / "models" / "templates" / "llama-cpp-rwkv-world.jinja"
1087+
if template_path.is_file():
10881088
with open(template_path, "r", encoding="utf-8") as f:
10891089
template = f.read()
10901090
else:

0 commit comments

Comments
 (0)