This is pretty darn crazy. One file runs on 6 operating systems, with GPU support.
yeah the section on how the GPU support works is wild!
Llamafile lets you distribute and run LLMs with a single file
11–20 of 302 posts
Re: Llamafile lets you distribute and run LLMs with a single file
#12This is a bit like specifying how large your strings will be to a C program. That was maybe accepted in the old days, but not anymore really.
Re: Llamafile lets you distribute and run LLMs with a single file
#13Re: Llamafile lets you distribute and run LLMs with a single file
#141. Download the 4.26GB llamafile-server-0.1-llava-v1.5-7b-q4 file from https://huggingface.co/jartine/llava-v1.5-7B-GGUF/blob/main/...:
wget https://huggingface.co/jartine/llava-v1.5-7B-GGUF/resolve/main/llamafile-server-0.1-llava-v1.5-7b-q4
2. Make that binary executable, by running this in a terminal: chmod 755 llamafile-server-0.1-llava-v1.5-7b-q4
3. Run your new executable, which will start a web server on port 8080: ./llamafile-server-0.1-llava-v1.5-7b-q4
4. Navigate to http://127.0.0.1:8080/ to upload an image and start chatting with the model about it in your browser.Screenshot here: https://simonwillison.net/2023/Nov/29/llamafile/
Re: Llamafile lets you distribute and run LLMs with a single file
#15> you pass the --n-gpu-layers 35 flag (or whatever value is appropriate) to enable GPU This is a bit like specifying how large your strings will be to a C program. That was maybe accepted in the old days, but not anymore really.
Re: Llamafile lets you distribute and run LLMs with a single file
#16Re: Llamafile lets you distribute and run LLMs with a single file
#17Re: Llamafile lets you distribute and run LLMs with a single file
#18Earlier quoted context omitted.
So if you share a binary with a friend you'd have to have them install cuda toolkit too? Seems like a dealbreaker for the whole idea.
> On Windows, that usually means you need to open up the MSVC x64 native command prompt and run llamafile there, for the first invocation, so it can build a DLL with native GPU support. After that, $CUDA_PATH/bin still usually needs to be on the $PATH so the GGML DLL can find its other CUDA dependencies. Yeah, I think the setup lost most users there. A separate model/app approach (like Koboldcpp) seems way easier TBH…
Re: Llamafile lets you distribute and run LLMs with a single file
#19Re: Llamafile lets you distribute and run LLMs with a single file
#20This is pretty darn crazy. One file runs on 6 operating systems, with GPU support.