Instructions to use alan13367/Qwen3.5-4B-RustCoder-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 alan13367/Qwen3.5-4B-RustCoder-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 alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf alan13367/Qwen3.5-4B-RustCoder-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 alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama cli -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
Use Docker
docker model run hf.co/alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
- Llama new
- LM Studio
- Jan
- Ollama
How to use alan13367/Qwen3.5-4B-RustCoder-GGUF with Ollama:
ollama run hf.co/alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
- Unsloth Desktop
- Pi
How to use alan13367/Qwen3.5-4B-RustCoder-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
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:9931/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use alan13367/Qwen3.5-4B-RustCoder-GGUF with Docker Model Runner:
docker model run hf.co/alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
- Lemonade
How to use alan13367/Qwen3.5-4B-RustCoder-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.Qwen3.5-4B-RustCoder-GGUF-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use alan13367/Qwen3.5-4B-RustCoder-GGUF with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
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:9931/v1 hermes config set model.default alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use alan13367/Qwen3.5-4B-RustCoder-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M
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:9931/v1 \ --custom-model-id "alan13367/Qwen3.5-4B-RustCoder-GGUF:Q4_K_M" \ --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"
|
Download README.md from alan13367/Qwen3.5-4B-RustCoder-GGUF: direct link, hf CLI and curl.
- Browser
- Download file 3.62 kB
-
https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder-GGUF/resolve/main/README.md
- Command line
-
hf download hf://alan13367/Qwen3.5-4B-RustCoder-GGUF/README.md
-
curl -L -o README.md https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder-GGUF/resolve/main/README.md
3.62 kB
| base_model: alan13367/Qwen3.5-4B-RustCoder | |
| base_model_relation: quantized | |
| license: apache-2.0 | |
| language: | |
| - en | |
| tags: | |
| - gguf | |
| - llama.cpp | |
| - qwen3.5 | |
| - rust | |
| - code | |
| # Qwen3.5-4B-RustCoder-GGUF | |
| GGUF quantizations of [alan13367/Qwen3.5-4B-RustCoder](https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder): [Qwen/Qwen3.5-4B](https://huggingface.co/Qwen/Qwen3.5-4B) fine-tuned to write Rust that compiles, passes tests and is clippy-clean, with its thinking mode kept. They are for llama.cpp and other GGUF runtimes. Text only: no vision projector is included. | |
| | File | Bits per weight | Size | Use | | |
| |---|---|---|---| | |
| | `Qwen3.5-4B-RustCoder-Q8_0.gguf` | 8.5 | 4.5 GB | Closest to the evaluated model | | |
| | `Qwen3.5-4B-RustCoder-Q4_K_M.gguf` | 5.2 | 2.7 GB | Smaller and faster, slightly less accurate | | |
| **Version 2 (2026-11-20).** A weighted merge of two LoRA fine-tunes, +3.2 points over the first release. The first release is still available at revision [`9b58a82`](https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder-GGUF/tree/9b58a825f51997d586fafe206e7ca56d34401699). | |
| Other versions: | |
| - [Qwen3.5-4B-RustCoder](https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder): bf16 safetensors, for transformers. | |
| - [Qwen3.5-4B-RustCoder-MLX-8bit](https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder-MLX-8bit): MLX, for Apple Silicon. This is the checkpoint that was trained and evaluated. | |
| ## Results of the fine-tune | |
| Pass rate on held-out Rust tasks with hidden tests: 4 samples per task in each of two evaluation runs, thinking on, no system prompt. These were measured on the MLX 8-bit checkpoint, not on the GGUF files. | |
| | Pass rate | Easy (29 tasks) | Hard (40) | Quality (29) | Dev (82) | All (180) | | |
| |---|---|---|---|---|---| | |
| | Qwen3.5-4B (8-bit) | 43.5% | 6.9% | 8.6% | 20.1% | 19.1% | | |
| | Qwen3.5-4B-RustCoder v2 | 53.0% | 8.1% | 15.9% | 23.6% | 23.7% | | |
| Pooled over all 180 tasks, the gain over the base is +4.6 points (95% CI +1.8 to +7.4). With a compiler in the loop (keep an answer that builds and is clippy-clean, retry with the errors) it reaches 38.9%, and 43.0% when its own unit tests choose among 8 answers. The data, the training and the limitations are in the [main model card](https://huggingface.co/alan13367/Qwen3.5-4B-RustCoder). | |
| ## Usage | |
| With [llama.cpp](https://github.com/ggml-org/llama.cpp) (a build with Qwen3.5 support): | |
| ```bash | |
| llama-server -hf alan13367/Qwen3.5-4B-RustCoder-GGUF:Q8_0 -c 8192 \ | |
| --temp 0.6 --top-p 0.95 --top-k 20 | |
| ``` | |
| Then send chat requests to `http://localhost:8080/v1/chat/completions`. Use `:Q4_K_M` for the smaller file. Other GGUF runtimes, such as Ollama and LM Studio, can load these files if their bundled llama.cpp supports the `qwen35` architecture. | |
| Recommended: | |
| - **Use no system prompt.** Training and evaluation used none. | |
| - **Leave thinking on.** The chat template thinks by default. | |
| - **Allow about 4096 output tokens and a context of at least 8192.** An answer that runs to the cap is usually stuck in a reasoning loop, so resampling helps more than a longer cap. | |
| - **Use temperature 0.6, top-p 0.95 and top-k 20.** These are the settings behind the results. | |
| ## Conversion | |
| Both files were converted from the bf16 weights with llama.cpp's `convert_hf_to_gguf.py` (build b12359), then quantized with `llama-quantize`, without an importance matrix. Perplexity on six of the model's training answers, rendered with its chat template (`llama-perplexity`, 2048-token chunks): Q8_0 1.379, Q4_K_M 1.387 (about 0.6% higher). | |
| ## License | |
| Apache 2.0, the license of the base model [Qwen/Qwen3.5-4B](https://huggingface.co/Qwen/Qwen3.5-4B). | |