janhq / cortex.cpp

Run and customize Local LLMs.
https://cortex.so
Apache License 2.0
1.96k stars 111 forks source link

bug: `cortex run`: Error: `Error: Please delete model before downloading again bug` #1408

Open gabrielle-ong opened 1 week ago

gabrielle-ong commented 1 week ago

Cortex version

v1.0.0-141

Describe the Bug

Issue faced when running an already downloaded huggingface model author/model_id

> cortex-nightly run bartowski/Meta-Llama-3.1-8B-Instruct-GGUF
...
Selected: Meta-Llama-3.1-8B-Instruct-Q2_K.gguf
Model already downloaded: bartowski:Meta-Llama-3.1-8B-Instruct-GGUF:Meta-Llama-3.1-8B-Instruct-Q2_K.gguf
Error: Please delete the model before downloading again
Error: Model not found

Expected behaviour:

  1. I expect it to run the downloaded model
  2. I expected the model alias to be the huggingface path bartowski/Meta-Llama-3.1-8B-Instruct-GGUF

Screenshots / Logs

Mac: image image

What is your OS?

What engine are you running?

gabrielle-ong commented 23 hours ago

Retrying this with v172, redownloading a already downloaded HF model bartowski/Meta-Llama-3.1-8B-Instruct-GGUF Getting an uncaught error, but cortex chat successfully runs

Selected: Meta-Llama-3.1-8B-Instruct-Q2_K.gguf
Model already downloaded: bartowski:Meta-Llama-3.1-8B-Instruct-GGUF:Meta-Llama-3.1-8B-Instruct-Q2_K.gguf
libc++abi: terminating due to uncaught exception of type cpp::bitwizeshift::bad_result_access<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>: error attempting to access value from result containing error
[1]    28174 abort      cortex-nightly run bartowski/Meta-Llama-3.1-8B-Instruct-GGUF

Image

gabrielle-ong commented 8 hours ago

Closing the original issue