Instructions to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- llama-cpp-python
How to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development with llama-cpp-python:
# !pip install llama-cpp-python from llama_cpp import Llama llm = Llama.from_pretrained( repo_id="cmp-nct/xcomposer2_gguf_for_llama.cpp_development", filename="ggml-model-q3ks.gguf", )
output = llm( "Once upon a time,", max_tokens=512, echo=True ) print(output)
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- llama.cpp
How to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development with llama.cpp:
Install from brew
brew install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16 # Run inference directly in the terminal: llama-cli -hf cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama-server -hf cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16 # Run inference directly in the terminal: llama-cli -hf cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
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 cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16 # Run inference directly in the terminal: ./llama-cli -hf cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
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 cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16 # Run inference directly in the terminal: ./build/bin/llama-cli -hf cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
Use Docker
docker model run hf.co/cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
- LM Studio
- Jan
- Ollama
How to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development with Ollama:
ollama run hf.co/cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
- Unsloth Studio new
How to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development 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 cmp-nct/xcomposer2_gguf_for_llama.cpp_development 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 cmp-nct/xcomposer2_gguf_for_llama.cpp_development to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for cmp-nct/xcomposer2_gguf_for_llama.cpp_development to start chatting
- Docker Model Runner
How to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development with Docker Model Runner:
docker model run hf.co/cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
- Lemonade
How to use cmp-nct/xcomposer2_gguf_for_llama.cpp_development with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull cmp-nct/xcomposer2_gguf_for_llama.cpp_development:F16
Run and chat with the model
lemonade run user.xcomposer2_gguf_for_llama.cpp_development-F16
List all available models
lemonade list
Doesn't work.
llm_load_print_meta: model type = 7B
llm_load_print_meta: model ftype = Q3_K - Small
llm_load_print_meta: model params = 8.34 B
llm_load_print_meta: model size = 3.48 GiB (3.58 BPW)
llm_load_print_meta: general.name = InternLM2
llm_load_print_meta: BOS token = 1 '''
llm_load_print_meta: EOS token = 2 '
llm_load_print_meta: UNK token = 0 ''
llm_load_print_meta: PAD token = 2 ''
llm_load_print_meta: LF token = 13 '<0x0A>'
llm_load_tensors: ggml ctx size = 0.23 MiB
llama_model_load: error loading model: done_getting_tensors: wrong number of tensors; expected 611, got 291
Sums match. Obsidian multi-modal gguf works. So there is a problem with the small model.
This is a development release, you'd need to use my PR to load those models.
The PR is incomplete, it will not apply the dynamic LORA which is needed for xcomposer2. xcomposer 2 uses additional tensors in the language architecture.
Due to the release of llava-1.6 I had stopped the integration work. Currently it is on pause, the work required to get xcomposer2 running is significant