Instructions to use Harsha001/Carbon-X-ROCmFPX 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 Harsha001/Carbon-X-ROCmFPX 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 Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP # Run inference directly in the terminal: llama cli -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP # Run inference directly in the terminal: llama cli -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
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 Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP # Run inference directly in the terminal: ./llama-cli -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
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 Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP # Run inference directly in the terminal: ./build/bin/llama-cli -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Use Docker
docker model run hf.co/Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
- LM Studio
- Jan
- vLLM
How to use Harsha001/Carbon-X-ROCmFPX with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Harsha001/Carbon-X-ROCmFPX" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Harsha001/Carbon-X-ROCmFPX", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
- Ollama
How to use Harsha001/Carbon-X-ROCmFPX with Ollama:
ollama run hf.co/Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
- Unsloth Desktop
- Pi
How to use Harsha001/Carbon-X-ROCmFPX with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use Harsha001/Carbon-X-ROCmFPX with Docker Model Runner:
docker model run hf.co/Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
- Lemonade
How to use Harsha001/Carbon-X-ROCmFPX with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Run and chat with the model
lemonade run user.Carbon-X-ROCmFPX-Q4_0_ROCMFP
List all available models
lemonade list
- Hermes Agent
How to use Harsha001/Carbon-X-ROCmFPX with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:8080/v1 hermes config set model.default Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use Harsha001/Carbon-X-ROCmFPX with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:8080/v1 \ --custom-model-id "Harsha001/Carbon-X-ROCmFPX:Q4_0_ROCMFP" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
Carbon-X โ ROCmFPX GGUF
HuggingFaceBio/Carbon-X, the 14.8B language model for DNA understanding and generation from Hugging Face Bio, quantized to the ROCmFPX formats, a llama.cpp fork with low-bit weight types for AMD GPUs (Vulkan and HIP/ROCm). Paste raw DNA into an ordinary chat message and the model answers in English: variant effects, regulatory regions, organism groups, next bases.
Start with Q6_0_ROCMFPX. It stays close to the original on DNA. The 4-bit files lose clearly more on DNA (see
below).
These files only load in a ROCmFPX build of llama.cpp. Stock llama.cpp, LM Studio and Ollama do not know these types; for those, use Hugging Face Bio's own Carbon-X-GGUF. These files have not been tested on AMD hardware yet.
Not an official release of Hugging Face Bio. All credit for the model goes to its authors.
Files and measured quality
Every file was scored twice against the BF16 model: on WikiText-2 test (40 chunks of 512 tokens, BF16 perplexity 9.2710) and on human DNA (42 segments of 3,072 bases from chromosomes 1 to 22 of the GRCh38 reference genome, taken from Ensembl, 512-token chunks, BF16 perplexity 1446.4). KLD is the mean KL divergence of the next-token distribution from BF16 (lower is better). Same top is how often the quant picks the same next token as BF16. Raw genome sequence is close to random, so on DNA the model is rarely sure of the next token and "same top" is low even for the 8-bit file; compare KLD there.
| File | Size | Text KLD | Text same top | DNA KLD | DNA same top | |
|---|---|---|---|---|---|---|
Carbon-X-Q8_0_ROCMFPX.gguf |
15.3 GB | 0.0032 | 97.24% | 0.0238 | 79.54% | 8-bit, closest to BF16 |
Carbon-X-Q6_0_ROCMFPX.gguf |
12.2 GB | 0.0084 | 95.57% | 0.0290 | 78.72% | Recommended. 6-bit, almost as close as 8-bit |
Carbon-X-Q4_0_ROCMFP4_STRIX.gguf |
8.7 GB | 0.0721 | 88.78% | 0.0968 | 71.85% | 4-bit recipe tuned for Strix Halo (gfx1151) |
Carbon-X-Q4_0_ROCMFP4_FAST.gguf |
8.7 GB | 0.0734 | 88.68% | 0.0963 | 72.01% | speed-first 4-bit (one scale per block) |
In both 4-bit files the token embedding and output tensors, which hold the DNA tokens, are stored as stock Q8_0, as
in Hugging Face Bio's own GGUFs. With those tensors at 4 bits, the files were 0.6 GB smaller but clearly worse
(DNA KLD 0.129, same top 63.0%), so they were not published.
For comparison, a stock Q4_K_M made the same way (same importance matrix, token embedding and output at Q8_0,
9.6 GB) measured text KLD 0.0334 and DNA KLD 0.0486, about half the loss of the 4-bit ROCmFPX files. If you need a
4-bit file and do not need the ROCmFPX types, Hugging Face Bio's carbon-x-q4_k_m.gguf is the better choice.
Not published: Q3_0_ROCMFPX (8.5 GB, text KLD 0.134, DNA KLD 0.169) is far from BF16 on both.
These numbers show how much each file changes the model's predictions, not benchmark accuracy, which was not measured.
Run
git clone https://github.com/HarshaVardhan3002/ROCmFPX && cd ROCmFPX
cmake -B build -DGGML_VULKAN=ON # or -DGGML_HIP=ON -DAMDGPU_TARGETS=gfx1151 (gfx1100 for RX 7900)
cmake --build build --target llama-server -j
build/bin/llama-server -m Carbon-X-Q6_0_ROCMFPX.gguf -ngl 999 -c 40960 --jinja \
--chat-template-kwargs '{"enable_thinking": false}' \
--temp 0.6 --top-p 0.95 --top-k 20 --min-p 0
Carbon-X was post-trained and evaluated with thinking disabled; the sampling settings are Hugging Face Bio's defaults.
The fork includes llama.cpp's support for Carbon's hybrid DNA tokenizer (upstream
#30825): runs of A/C/G/T in a prompt are tagged as DNA and cut into
6-base tokens automatically. On 9 test strings (the model card examples, lowercase bases, lengths that are not a
multiple of 6, N and other ambiguity codes, space-separated blocks, short words such as "CAT", the chat format and
1,000 bases of human DNA) llama.cpp produced exactly the same token ids as Hugging Face Bio's Python tokenizer.
Answer from Carbon-X-Q4_0_ROCMFP4_STRIX.gguf (CPU backend, greedy) to the model card's variant question
(...CCTGAGGAG... to ...CCTGTGGAG...): "The variant changes position 21 from A to T, so GAG becomes GTG. ..."
How these were made
convert_hf_to_gguf.py --outtype bf16from the fork.- Importance matrix from the BF16 model on the GPU over a general calibration text (
calibration_datav3), 512-token chunks. llama-quantize --imatrix, one run per type (4-bit files with--token-embedding-type q8_0 --output-tensor-type q8_0), from HarshaVardhan3002/ROCmFPX.- Quality: the BF16 reference ran on an NVIDIA GPU with stock BF16 kernels. Each quant was expanded back to F16
(
llama-quantize --allow-requantize ... F16), which keeps its stored weights, and scored on the same GPU with stock F16 kernels. The fork's own CUDA kernels for these types are not correct on NVIDIA, so they were not used. As a check, this method gave KLD 0.0050 for a 9B model'sQ8_0_ROCMFPXwhere the CPU backend gave 0.0054. AMD GPU kernels compute the same math in a different order, so results on an AMD GPU can differ slightly.
Carbon-X's weights are of normal size, so no tensor scales were needed (unlike ROCmFPX#118). Other ROCmFPX builds load these files too, but they need llama.cpp b11742 or newer underneath, or DNA is tokenized wrongly.
Limitations
Carbon-X is a research model. Do not use its answers for medical decisions. See the original model card.
License
Apache-2.0, same as the base model.
- Downloads last month
- 57