Text Generation
GGUF
English
llama.cpp
unsloth
lora
reasoning
chain-of-thought
distillation
claude
claude-opus
qwen
qwen3.8
dense
mtp
speculative-decoding
conversational
Instructions to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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 rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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 rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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 rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M # Run inference directly in the terminal: llama cli -hf rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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 rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M # Run inference directly in the terminal: ./llama-cli -hf rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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 rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M # Run inference directly in the terminal: ./build/bin/llama-cli -hf rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
Use Docker
docker model run hf.co/rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
- LM Studio
- Jan
- vLLM
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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": "rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
- Ollama
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF with Ollama:
ollama run hf.co/rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
- Unsloth Desktop
- Pi
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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:8080/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF with Docker Model Runner:
docker model run hf.co/rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
- Lemonade
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
Run and chat with the model
lemonade run user.Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF-Q4_K_M
List all available models
lemonade list
- Hermes Agent
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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 rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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:8080/v1 hermes config set model.default rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF:Q4_K_M
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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:8080/v1 \ --custom-model-id "rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-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"
Upload folder using huggingface_hub
Browse files- .gitattributes +5 -0
- README.md +134 -0
- qwen3.8-27b-opus-distill.Q4_K_M.gguf +3 -0
- qwen3.8-27b-opus-distill.Q5_K_M.gguf +3 -0
- qwen3.8-27b-opus-distill.Q6_K.gguf +3 -0
- qwen3.8-27b-opus-distill.Q8_0.gguf +3 -0
- qwen3.8-27b-opus-distill.f16.gguf +3 -0
.gitattributes
CHANGED
|
@@ -33,3 +33,8 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 33 |
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 34 |
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 35 |
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
qwen3.8-27b-opus-distill.Q4_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
qwen3.8-27b-opus-distill.Q5_K_M.gguf filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
qwen3.8-27b-opus-distill.Q6_K.gguf filter=lfs diff=lfs merge=lfs -text
|
| 39 |
+
qwen3.8-27b-opus-distill.Q8_0.gguf filter=lfs diff=lfs merge=lfs -text
|
| 40 |
+
qwen3.8-27b-opus-distill.f16.gguf filter=lfs diff=lfs merge=lfs -text
|
README.md
ADDED
|
@@ -0,0 +1,134 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: apache-2.0
|
| 3 |
+
datasets:
|
| 4 |
+
- lordx64/reasoning-distill-claude-opus-4-7-max
|
| 5 |
+
- Jackrong/Claude-opus-4.7-TraceInversion-5000x
|
| 6 |
+
- Jackrong/Claude-opus-4.6-TraceInversion-9000x
|
| 7 |
+
language:
|
| 8 |
+
- en
|
| 9 |
+
base_model: Qwen/Qwen3.8-27B
|
| 10 |
+
pipeline_tag: text-generation
|
| 11 |
+
library_name: gguf
|
| 12 |
+
tags:
|
| 13 |
+
- gguf
|
| 14 |
+
- llama.cpp
|
| 15 |
+
- unsloth
|
| 16 |
+
- lora
|
| 17 |
+
- reasoning
|
| 18 |
+
- chain-of-thought
|
| 19 |
+
- distillation
|
| 20 |
+
- claude
|
| 21 |
+
- claude-opus
|
| 22 |
+
- qwen
|
| 23 |
+
- qwen3.8
|
| 24 |
+
- dense
|
| 25 |
+
- mtp
|
| 26 |
+
- speculative-decoding
|
| 27 |
+
---
|
| 28 |
+
|
| 29 |
+
# Qwen3.8-27B-Claude-Opus-Reasoning-Distilled-GGUF
|
| 30 |
+
|
| 31 |
+

|
| 32 |
+

|
| 33 |
+

|
| 34 |
+

|
| 35 |
+

|
| 36 |
+
|
| 37 |
+
GGUF quantizations of [rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled](https://huggingface.co/rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled) β a LoRA fine-tune of **Qwen/Qwen3.8-27B** distilled on reasoning traces from **Claude Opus 4.6/4.7**, merged to 16-bit and quantized for local inference with llama.cpp / Ollama / LM Studio.
|
| 38 |
+
|
| 39 |
+
**MTP (Multi-Token Prediction) head verified working for self-speculative decoding β see below, ~1.6Γ speedup.**
|
| 40 |
+
|
| 41 |
+
## π§ What this is
|
| 42 |
+
|
| 43 |
+
Qwen3.8-27B is natively vision-language with a hybrid attention stack (16/64 full-attention layers, 48/64 Gated DeltaNet/linear-attention layers) plus a Multi-Token Prediction head. This fine-tune targets **only the text reasoning path**; the vision tower is present in the merge (unmodified base weights) but was not targeted by LoRA.
|
| 44 |
+
|
| 45 |
+
- **Base model:** [Qwen/Qwen3.8-27B](https://huggingface.co/Qwen/Qwen3.8-27B) (dense, 27B, hybrid linear+full attention, MTP head)
|
| 46 |
+
- **Method:** LoRA (r=32, alpha=32) via [Unsloth](https://github.com/unslothai/unsloth), merged to 16-bit, converted with [llama.cpp](https://github.com/ggml-org/llama.cpp) (latest build β required for hybrid Gated DeltaNet operator support)
|
| 47 |
+
- **Training data:** ~21.5K examples combining real Opus extended-thinking traces and reconstructed-reasoning traces over genuine Opus outputs (see Dataset Composition below)
|
| 48 |
+
|
| 49 |
+
## π Training Details
|
| 50 |
+
|
| 51 |
+
| | |
|
| 52 |
+
|---|---|
|
| 53 |
+
| Steps trained | 150 (partial run β pipeline validation, not full convergence) |
|
| 54 |
+
| Epochs | 0.126 (~12.6% of one epoch, ~2,700 of 21,490 examples) |
|
| 55 |
+
| Effective batch size | 18 (per-device 6 Γ grad accum 3) |
|
| 56 |
+
| Final train loss (avg) | 0.728 |
|
| 57 |
+
| Sequence length | 8192 (99.7% of dataset uncut; 0.3% longest examples excluded rather than truncated) |
|
| 58 |
+
| Trainable params (LoRA) | 233,455,616 (0.85% of 27.6B) |
|
| 59 |
+
|
| 60 |
+
> **Status: pipeline-validation run, not a fully converged model.** 150 steps at batch 18 covers ~12.6% of one epoch β enough to confirm the training pipeline works end-to-end (LoRA on hybrid attention, masking, chat template, checkpointing, merge, GGUF conversion, MTP preservation), not enough for the model to have generalized across the full dataset. A full run (1+ epoch, ~1,194+ steps) is needed before this should be treated as a finished distillation.
|
| 61 |
+
|
| 62 |
+
## π Dataset Composition
|
| 63 |
+
|
| 64 |
+
| Source | Examples | What it is |
|
| 65 |
+
|---|---:|---|
|
| 66 |
+
| [lordx64/reasoning-distill-claude-opus-4-7-max](https://huggingface.co/datasets/lordx64/reasoning-distill-claude-opus-4-7-max) | 8,124 | Genuine Claude Opus 4.7 extended-thinking traces (verified `model`/`usage` fields per row) |
|
| 67 |
+
| [Jackrong/Claude-opus-4.7-TraceInversion-5000x](https://huggingface.co/datasets/Jackrong/Claude-opus-4.7-TraceInversion-5000x) | 4,800 | Real Opus 4.7 outputs (`teacher_model` field), reasoning trace reconstructed post-hoc by a smaller "trace inversion" model |
|
| 68 |
+
| [Jackrong/Claude-opus-4.6-TraceInversion-9000x](https://huggingface.co/datasets/Jackrong/Claude-opus-4.6-TraceInversion-9000x) | 8,700 | Same trace-inversion method, Opus 4.6 |
|
| 69 |
+
|
| 70 |
+
**Transparency note:** ~62% of the dataset has a *genuine* final answer from Opus but a *reconstructed* reasoning trace, not Opus's actual internal thinking. The lordx64 subset (~38%) is the closest to authentic Opus thinking style. Full details on the [base LoRA repo](https://huggingface.co/rico03/Qwen3.8-27B-Claude-Opus-Reasoning-Distilled).
|
| 71 |
+
|
| 72 |
+
## β‘ MTP / Speculative Decoding
|
| 73 |
+
|
| 74 |
+
The Multi-Token Prediction head from the base model (`blk.64.nextn.*`) survives the LoRA merge and GGUF conversion intact and is functional for self-speculative decoding β verified on Q8_0:
|
| 75 |
+
|
| 76 |
+
| Mode | Generation speed (H100 NVL) |
|
| 77 |
+
|---|---:|
|
| 78 |
+
| Standard decoding | 64.6 tok/s |
|
| 79 |
+
| `--spec-type draft-mtp` | **104.2 tok/s** (~1.6Γ speedup) |
|
| 80 |
+
|
| 81 |
+
```bash
|
| 82 |
+
llama-cli -m qwen3.8-27b-opus-distill.Q8_0.gguf -p "your prompt" -ngl 99 --spec-type draft-mtp
|
| 83 |
+
```
|
| 84 |
+
|
| 85 |
+
No separate draft model needed β the MTP head inside this same GGUF file acts as the draft. Output quality is unaffected (MTP proposes candidate tokens that the main model verifies; it doesn't change what gets generated, only how fast). Requires a recent llama.cpp build with `--spec-type draft-mtp` support.
|
| 86 |
+
|
| 87 |
+
## π¦ Available Quantizations
|
| 88 |
+
|
| 89 |
+
| File | Size | Notes |
|
| 90 |
+
|---|---:|---|
|
| 91 |
+
| `qwen3.8-27b-opus-distill.f16.gguf` | 51 GB | Full precision, source for further quantization |
|
| 92 |
+
| `qwen3.8-27b-opus-distill.Q8_0.gguf` | 28 GB | Near-lossless, recommended if VRAM allows |
|
| 93 |
+
| `qwen3.8-27b-opus-distill.Q6_K.gguf` | 21 GB | Good quality/size trade-off |
|
| 94 |
+
| `qwen3.8-27b-opus-distill.Q5_K_M.gguf` | 19 GB | |
|
| 95 |
+
| `qwen3.8-27b-opus-distill.Q4_K_M.gguf` | 16 GB | Practical for single consumer GPU (24GB card) |
|
| 96 |
+
|
| 97 |
+
All quants verified to generate coherent output (Q8_0 sanity-tested with a technical prompt before upload). MTP speculative decoding available on all quants sharing the same architecture.
|
| 98 |
+
|
| 99 |
+
**β οΈ Requires a recent llama.cpp build.** This model uses Qwen3.8's hybrid Gated DeltaNet + Gated Attention architecture β older llama.cpp builds will not load it correctly. Build from source (`main` branch) if your package manager's version is stale.
|
| 100 |
+
|
| 101 |
+
## π Usage
|
| 102 |
+
|
| 103 |
+
### llama.cpp
|
| 104 |
+
|
| 105 |
+
```bash
|
| 106 |
+
./llama-cli -m qwen3.8-27b-opus-distill.Q8_0.gguf -p "Explain the difference between TCP and UDP." -ngl 99 --temp 1.0 --top-p 0.95 --top-k 20
|
| 107 |
+
```
|
| 108 |
+
|
| 109 |
+
With MTP speculative decoding (faster, same output distribution):
|
| 110 |
+
|
| 111 |
+
```bash
|
| 112 |
+
./llama-cli -m qwen3.8-27b-opus-distill.Q8_0.gguf -p "Explain the difference between TCP and UDP." -ngl 99 --temp 1.0 --top-p 0.95 --top-k 20 --spec-type draft-mtp
|
| 113 |
+
```
|
| 114 |
+
|
| 115 |
+
### Ollama / LM Studio
|
| 116 |
+
|
| 117 |
+
Download the `.gguf` file matching your VRAM budget from the Files tab and point Ollama/LM Studio at it directly (Modelfile/import instructions per their respective docs).
|
| 118 |
+
|
| 119 |
+
Thinking is on by default (`<think>...</think>` block before the final answer), matching the base Qwen3.8 chat template.
|
| 120 |
+
|
| 121 |
+
## β οΈ Known Limitations
|
| 122 |
+
|
| 123 |
+
- **This checkpoint is a pipeline-validation run (150 steps, ~12.6% of one epoch), not a fully converged fine-tune.** Expect it to show the target `<think>` format and some stylistic shift, but not robust generalization across task domains.
|
| 124 |
+
- Dataset partially composed of reconstructed (not captured) reasoning traces β see Dataset Composition above
|
| 125 |
+
- Text-only fine-tune; vision tower weights are present in the merge (unmodified base) but untested/unused in this GGUF export
|
| 126 |
+
- Requires latest llama.cpp for hybrid attention + MTP support (see note above)
|
| 127 |
+
|
| 128 |
+
## π Acknowledgments
|
| 129 |
+
|
| 130 |
+
Training methodology based on the [Jackrong fine-tuning guide](https://github.com/Jackrong). Thanks to lordx64 and Jackrong for the source reasoning datasets, and the llama.cpp team for hybrid-architecture support.
|
| 131 |
+
|
| 132 |
+
---
|
| 133 |
+
|
| 134 |
+
Maintained by rico03
|
qwen3.8-27b-opus-distill.Q4_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:d88819a7bbbd1ee6cee2169eec16e8cc51de759cb6aff2f621e60564ec9a7ac6
|
| 3 |
+
size 16810714336
|
qwen3.8-27b-opus-distill.Q5_K_M.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:41c5bdc6719eb2f49fc28dffed471c57135de976774131045c1b57c1dbed382c
|
| 3 |
+
size 19535701216
|
qwen3.8-27b-opus-distill.Q6_K.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:f20a86da392455d4e41eb1a4049750fc7eab234d96483866047fb84c7ecbef16
|
| 3 |
+
size 22430999776
|
qwen3.8-27b-opus-distill.Q8_0.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:09379075cf890ebbef92886f40b58ebd0969422b7c32a4e764bf063a10c0dbea
|
| 3 |
+
size 29047084256
|
qwen3.8-27b-opus-distill.f16.gguf
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cb7e0fd4e23c97aea5199a5784e60875a8c8be07865217d265743eab6ed96a3b
|
| 3 |
+
size 54657733856
|