Instructions to use dranger003/c4ai-command-r-plus-iMat.GGUF with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use dranger003/c4ai-command-r-plus-iMat.GGUF with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
Use pre-built binary
# Download pre-built binary from: # https://github.com/ggerganov/llama.cpp/releases # Start a local OpenAI-compatible server with a web UI: ./llama-server -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggerganov/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-server llama-cli # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama-server -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
Use Docker
docker model run hf.co/dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use dranger003/c4ai-command-r-plus-iMat.GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "dranger003/c4ai-command-r-plus-iMat.GGUF" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "dranger003/c4ai-command-r-plus-iMat.GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
- Ollama
How to use dranger003/c4ai-command-r-plus-iMat.GGUF with Ollama:
ollama run hf.co/dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
- Unsloth Studio
How to use dranger003/c4ai-command-r-plus-iMat.GGUF with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for dranger003/c4ai-command-r-plus-iMat.GGUF to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for dranger003/c4ai-command-r-plus-iMat.GGUF to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for dranger003/c4ai-command-r-plus-iMat.GGUF to start chatting
- Docker Model Runner
How to use dranger003/c4ai-command-r-plus-iMat.GGUF with Docker Model Runner:
docker model run hf.co/dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
- Lemonade
How to use dranger003/c4ai-command-r-plus-iMat.GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull dranger003/c4ai-command-r-plus-iMat.GGUF:Q4_K_M
Run and chat with the model
lemonade run user.c4ai-command-r-plus-iMat.GGUF-Q4_K_M
List all available models
lemonade list
- Atomic Chat
Can't merge files with gguf
When I try to merge the two parts of iq4_xs I get an error: gguf_init_from_file: invalid magic characters '¿≤:°' and then it destroys the file
MINGW64 ~/.cache/lm-studio/models/dranger003/c4ai-command-r-plus-iMat.GGUF/join
$ ls -l
total 54877592
-rw-r--r-- 1 J 197121 48653614944 Apr 14 03:50 ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf
-rw-r--r-- 1 J 197121 7547577984 Apr 16 20:20 ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf
MINGW64 ~/.cache/lm-studio/models/dranger003/c4ai-command-r-plus-iMat.GGUF/join
$ ../../../../../../LLM/llama-b2687-bin-win-cuda-cu11.7.1-x64/gguf-split.exe --merge ggml-c4ai-command-r-plus-104b-iq4_xs
-00001-of-00002.gguf ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf
gguf_merge: ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf -> ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf
gguf_merge: reading metadata ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf done
gguf_merge: reading metadata ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf ...gguf_init_from_file: invalid magic characters '¿≤:°'
gguf_merge: failed to load input GGUF from ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf
MINGW64 ~/.cache/lm-studio/models/dranger003/c4ai-command-r-plus-iMat.GGUF/join
$ ls -l
total 47507140
-rw-r--r-- 1 J 197121 48653614944 Apr 14 03:50 ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf
-rw-r--r-- 1 J 197121 0 Apr 16 20:37 ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf
These other bugs are possibly related or caused by this:
https://huggingface.co/dranger003/c4ai-command-r-plus-iMat.GGUF/discussions/12
https://huggingface.co/dranger003/c4ai-command-r-plus-iMat.GGUF/discussions/11
@zedmango You need to use
gguf-split, do you know how lm studio is merging?
That was me on the command line, not lm studio. I used gguf-split --merge. See what I put above:
$ ../../../../../../LLM/llama-b2687-bin-win-cuda-cu11.7.1-x64/gguf-split.exe --merge ggml-c4ai-command-r-plus-104b-iq4_xs -00001-of-00002.gguf ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf
I entered that command into the command line and got the above error. Using gguf-split --merge.
I don't think you're supposed to specify all the parts, just the first one but I can't test this right now. Also, which commit hash are you on? I think they may recently have changed how gguf-split works.
Thank you! That worked:
j@LAPTOP-QD5K4715:/mnt/c/Users/J/.cache/lm-studio/models/dranger003/c4ai-command-r-plus-iMat.GGUF/join
$ ../../../../../../LLM/llama-b2687-bin-win-cuda-cu11.7.1-x64/gguf-split.exe --merge ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf ggml-c4ai-command-r-plus-104b-iq4_xs.gguf
gguf_merge: ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf -> ggml-c4ai-command-r-plus-104b-iq4_xs.gguf
gguf_merge: reading metadata ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf done
gguf_merge: reading metadata ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf done
gguf_merge: writing tensors ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf done
gguf_merge: writing tensors ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf done
gguf_merge: ggml-c4ai-command-r-plus-104b-iq4_xs.gguf merged from 2 split with 642 tensors.
Oops, left out the command - here it is
gguf_merge: ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf -> ggml-c4ai-command-r-plus-104b-iq4_xs.gguf
gguf_merge: reading metadata ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf done
gguf_merge: reading metadata ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf done
gguf_merge: writing tensors ggml-c4ai-command-r-plus-104b-iq4_xs-00001-of-00002.gguf done
gguf_merge: writing tensors ggml-c4ai-command-r-plus-104b-iq4_xs-00002-of-00002.gguf done
gguf_merge: ggml-c4ai-command-r-plus-104b-iq4_xs.gguf merged from 2 split with 642 tensors.```
Anyway, thank you!