meta-llama / llama-models

Utilities intended for use with Llama models.
Other
4.88k stars 838 forks source link

Command 'llama' not found #202

Closed 976268367 closed 1 week ago

976268367 commented 3 weeks ago

Even when I enter the command 'pip install llama-stack' and it executes successfully, I still encounter the error 'Command 'llama' not found. issue

Reubencfernandes commented 3 weeks ago

Hi, I had the same issue.

The reason this was happening is because it wasn't added to the system environment PATH.

You have to add this to your system environment PATH:

C:\Users\USER\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\Scripts
LiangruXie commented 3 weeks ago

Did you solve this problem? I have the same problem.

mter4n commented 2 weeks ago

Same problem here!

976268367 commented 2 weeks ago

I solved this problem, which may be due to the fact that my virtual environment was actually a nested environment. After I deleted this virtual environment and resolved the nested environment issue, I recreated a Python 3.11 environment (I'm not sure if it's due to the Python version). At this point, I was able to use the llama command again. By the way, a way to check if your environment is a nested environment is to use conda info. If the displayed shell level is 1, there is no problem; if it is 2 or higher, there is an issue (I was at level 3 at the time). @mter4n @LiangruXie @Reubencfernandes

Inspirathon commented 2 weeks ago

Hi, I had the same issue.

The reason this was happening is because it wasn't added to the system environment PATH.

You have to add this to your system environment PATH:

C:\Users\USER\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.11_qbz5n2kfra8p0\LocalCache\local-packages\Python311\Scripts

This solved my problem

paulorenanmelo commented 2 weeks ago

I had the same issue. The only thing that worked for me was installing python 3.10.11, I was previously on 3.9

mhscentral commented 1 week ago

I had this issue on Python 3.9.6 in my venv. Upgrading to Python version 3.13 solved the issue. I can now access the CLI. I didn't need to do anything else with the PATH environment variable,

976268367 commented 1 week ago

It’s likely that the issue is related to the Python version. I created a new environment to eliminate the nested virtual environment issue, and the version of the new environment is 3.11.10, under which it runs successfully.

varunfb commented 1 week ago

This is more of an environment issue when you have nested environments. This is not a llama-stack cli issue. Closing out this task for this reason.