Run this model with HF Jobs
Run AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModel tokenizer = AutoTokenizer.from_pretrained("AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2") model = AutoModel.from_pretrained("AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2
- SGLang
How to use AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 with Docker Model Runner:
docker model run hf.co/AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2
AX Qwen3.8 27B Tendem DFlash2
A speculative drafter for Qwen 3.8 27B. It proposes blocks of 16 tokens; the target model verifies every proposal and decides the output, so a better drafter makes the same model answer faster.
This one is the public DFlash 2 drafter
fine-tuned by AX Tendem for the tree route of
AX Engine for SGLang. It is served in the public drafter's place: the architecture
and config.json are unchanged, only model.safetensors differs.
Quick start
You need Linux, Python 3.11 or 3.12, and an NVIDIA GPU the engine supports with a CUDA 13 driver. The GPU holds two models: 20.1 GB of weights for the target pack and 3.7 GB for this drafter, plus the server's caches (the engine's GPU memory table has the totals). The measurements here ran on RTX PRO 6000.
1. Install the engine. The wheel brings SGLang 0.5.23 with it.
python3.12 -m venv .venv && source .venv/bin/activate
pip install \
https://github.com/defai-digital/ax-engine-sglang/releases/download/v0.6.4/ax_engine_sglang-0.6.4-py3-none-any.whl
2. Serve. The launcher takes Hugging Face repository names, downloads what is missing and fills the tree settings itself.
ax-engine-sglang serve RadixArk/Qwen3.8-27B-NVFP4 \
--speculative-algorithm FC1_DFLASH_TREE \
--speculative-draft-model-path AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 \
--speculative-num-draft-tokens 16
3. Ask it something. The server speaks the OpenAI API, on port 30000 unless --port says
otherwise.
curl -s http://127.0.0.1:30000/v1/chat/completions -H 'Content-Type: application/json' -d '{
"model": "RadixArk/Qwen3.8-27B-NVFP4", "temperature": 0, "max_tokens": 256,
"chat_template_kwargs": {"enable_thinking": false},
"messages": [{"role": "user", "content": "Write a Python function that merges two sorted lists."}]
}'
Three things to keep:
- 16 draft tokens. The drafter was trained on 16-token blocks, and the
config.jsonit shares with the public drafter says 8. - Greedy requests. The numbers are for temperature 0 with thinking off. Sampling was not measured.
- Versions. 0.6.4 is the engine release the numbers here were taken on; newer releases are on the engine's release page. The launcher line is the one the engine documents for the public drafter with this drafter's name in its place. The timings were not taken with it but with the explicit launch under The measured launch.
At a glance
Development results on rented RTX PRO 6000 hosts, 16-block 32-node lattice tree, with the NVFP4 pack of the target:
| Speed against the public DFlash 2 drafter, one request | +3.5% to 5.9% on three hosts |
| The same recipe with another training seed | +0.4% to 2.6% |
| Four and eight requests, lattice tree | +5.8% and +6.1% |
| Task problems passed, of 921 | 845 and 850 on two hosts; direct decoding 845 |
| Size | 3.85 GB file, 3.7 GB on the GPU beside 20.1 GB for the target pack |
The speed is measured on 200 prompts that no drafter was selected on. Part of this checkpoint's margin is its seed: the second line is the same recipe trained with another one.
Read before use
- These are development results on rented RTX PRO 6000 hosts. They are not a guarantee for other GPUs, engines, target packs, sampling settings or prompt mixes.
- The tree route on this pack is not token-identical to direct decoding, with this drafter or with the public one. The measure used here is task quality, not an identical token stream.
- The gain is a few percent and differs between hosts of the same GPU model. It comes from more accepted tokens per verify round, and it is larger on code and math than on chat.
- An experimental 4-bit copy is AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2-NVFP4. It does not load in stock SGLang; this one is the default.
Speed
ax-engine-sglang 0.6.4 (b7812df) on SGLang 0.5.23, RadixArk/Qwen3.8-27B-NVFP4, 16-block
32-node lattice tree, one request, greedy, thinking off, 256 output tokens per prompt, two passes
per lane. The public drafter is measured before and after the fine-tunes in the same session.
Intervals resample prompts within families (10,000 draws); they cover the choice of prompts, not
hosts, days or training seeds.
Second holdout (60 MBPP train problems, 60 GSM8K test problems, 80 UltraChat test first turns; fixed before any drafter was run on it, and not used to choose this drafter):
First host:
| Drafter | tok/s | Over the public drafter | Tokens per verify (code, math, chat) |
|---|---|---|---|
| public DFlash2 | 234.8 | 6.04, 9.41, 4.30 | |
this drafter (B16L42) |
243.0 | ร1.035 (0.999 to 1.071) | 6.50, 9.92, 4.37 |
B16L43 |
235.6 | ร1.004 (0.974 to 1.034) | 5.83, 10.14, 4.31 |
B16P42 |
243.0 | ร1.035 (1.001 to 1.070) | 6.13, 10.28, 4.44 |
Direct decoding of the pack in the same session: 57.1 tok/s. Requests whose 256 tokens equal direct decoding: 4 of 200 (public drafter), 1 of 200 (this drafter).
Second host:
| Drafter | tok/s | Over the public drafter | Tokens per verify (code, math, chat) |
|---|---|---|---|
| public DFlash2 | 238.7 | 5.49, 9.28, 4.34 | |
this drafter (B16L42) |
252.7 | ร1.059 (1.025 to 1.093) | 6.14, 10.13, 4.43 |
B16L43 |
244.9 | ร1.026 (0.995 to 1.058) | 5.63, 10.16, 4.36 |
B16P42 |
251.0 | ร1.052 (1.014 to 1.091) | 6.00, 10.01, 4.46 |
Direct decoding of the pack in the same session: 57.3 tok/s. Requests whose 256 tokens equal direct decoding: 2 of 200 (public drafter), 3 of 200 (this drafter).
Third host:
| Drafter | tok/s | Over the public drafter | Tokens per verify (code, math, chat) |
|---|---|---|---|
| public DFlash2 | 242.9 | 6.06, 9.35, 4.28 | |
this drafter (B16L42) |
252.1 | ร1.038 (1.003 to 1.072) | 6.41, 9.92, 4.38 |
B16L43 |
244.6 | ร1.007 (0.978 to 1.036) | 5.78, 10.17, 4.33 |
B16P42 |
252.9 | ร1.041 (1.006 to 1.078) | 6.24, 10.21, 4.42 |
Direct decoding of the pack earlier that evening on the same GPU: 57.3 tok/s. Requests whose 256 tokens equal direct decoding: 4 of 200 (public drafter), 2 of 200 (this drafter).
B16L43 is the same recipe with training seed 43. B16P42 is the earlier fine-tune
this recipe comes from; its training text includes prompts under a non-commercial licence, so it
is not published.
First holdout (60 HumanEval, 60 GSM8K test and 80 chat prompts, the set of the project's earlier records; fine-tune recipes were compared on it, so a number on it is an optimistic estimate for the recipe):
Third host:
| Drafter | tok/s | Over the public drafter | Tokens per verify (code, math, chat) |
|---|---|---|---|
| public DFlash2 | 268.8 | 9.46, 8.84, 4.40 | |
this drafter (B16L42) |
284.6 | ร1.059 (1.039 to 1.080) | 10.67, 9.73, 4.51 |
B16L43 |
285.3 | ร1.062 (1.038 to 1.085) | 10.14, 9.84, 4.58 |
B16P42 |
286.9 | ร1.068 (1.046 to 1.090) | 10.50, 9.74, 4.60 |
First host:
| Drafter | tok/s | Over the public drafter | Tokens per verify (code, math, chat) |
|---|---|---|---|
| public DFlash2 | 259.9 | 9.31, 9.00, 4.41 | |
this drafter (B16L42) |
274.3 | ร1.055 (1.033 to 1.078) | 10.67, 9.70, 4.50 |
B16P42 |
275.8 | ร1.061 (1.035 to 1.087) | 10.14, 9.61, 4.63 |
More than one request (first holdout prompts, second host, one session: public drafter, this drafter, public drafter again; one pass per cell):
| Route | Requests | Public drafter tok/s, before and after | This drafter tok/s | Change against their mean |
|---|---|---|---|---|
| lattice tree, 32 nodes | 1 | 273.0, 271.8 | 289.0 | +6.1% |
| lattice tree, 32 nodes | 4 | 599.6, 594.6 | 631.5 | +5.8% |
| lattice tree, 32 nodes | 8 | 870.1, 859.7 | 918.0 | +6.1% |
| batched tree, 8 nodes | 1 | 257.5, 255.4 | 268.2 | +4.6% |
| batched tree, 8 nodes | 4 | 802.1, 795.4 | 817.2 | +2.3% |
| batched tree, 8 nodes | 8 | 1303.2, 1293.9 | 1318.0 | +1.5% |
The public drafter's two launches differ by up to 1.2% in a cell, so the lattice tree's gain is resolved at every request count and the batched tree's gain at four and eight requests is close to that variation.
Task quality
Answers of natural length (stop token or 1,024 tokens), greedy, thinking off: 164 HumanEval, 257 MBPP (sanitized test) and the first 500 GSM8K test problems. The project accepts a drafter when its route passes no fewer problems than direct decoding of the target over the three sets.
| Lane | Host | HumanEval | MBPP | GSM8K | Of 921 |
|---|---|---|---|---|---|
| direct decoding | first host | 155 | 215 | 475 | 845 |
tree, this drafter (B16L42) |
first host | 154 | 216 | 475 | 845 |
tree, this drafter (B16L42) |
second host | 154 | 218 | 478 | 850 |
tree, B16L43 |
third host | 155 | 216 | 473 | 844 |
tree, B16L43 |
second host | 157 | 217 | 478 | 852 |
One run per lane and host. This drafter was chosen on the first-host run, where it passes as many
problems as direct decoding; B16L43 passed one fewer than direct decoding on its own first run
(third host) and is not published. The second-host runs repeat both afterwards: the same weights
pass a few problems more or fewer on another host, which is larger than either drafter's
difference to direct decoding. There is no chat quality check.
The measured launch
The numbers above are from this launch, with ax-engine-sglang 0.6.4 installed as an SGLang plugin and both models in local directories:
hf download RadixArk/Qwen3.8-27B-NVFP4 --revision 319f741cce68d7914884900c138a1fbb70a42f30 \
--local-dir ./Qwen3.8-27B-NVFP4
hf download AutomatosX/AX-Qwen3.8-27B-Tendem-DFlash2 --local-dir ./AX-Qwen3.8-27B-Tendem-DFlash2
SGLANG_PLUGINS=ax-engine AX_TREE=1 AX_LATTICE=1 AX_FAST=1 AX_TIME=1 \
AX_CHAIN_WIDTH=16 AX_CHAIN_GRAPH_WIDTHS="16 8" AX_GDN_LAYERS=48 AX_GDN_HEADS=48 \
FC1_TREE64=1 FC1_BRANCH_PILOT=1 FC1_OURS=1 FC1_FUSED=1 FC1_COMPILE_BUILD=1 \
FC1_DRAFT_BLOCK=16 FC1_TREE_N=32 \
python -m sglang.launch_server \
--model-path ./Qwen3.8-27B-NVFP4 \
--speculative-algorithm FC1_DFLASH_TREE \
--speculative-draft-model-path ./AX-Qwen3.8-27B-Tendem-DFlash2 \
--speculative-num-draft-tokens 16 \
--max-running-requests 2 --cuda-graph-max-bs-decode 2 \
--context-length 8192 --max-total-tokens 32768 --mem-fraction-static 0.82 \
--disable-radix-cache --attention-backend flashinfer --fp4-gemm-backend flashinfer_cutlass
It differs from the quick start in what it pins: the target pack's revision, two request slots,
the context length and the CUTLASS FP4 backend. tendem.json records the pairing for tools: the
target pack with its revision and file digests, the 16 draft tokens and the versions measured.
Apple silicon (MLX)
The file keeps the public drafter's layout, and one development check exists: AX Engine on an Apple M2 Ultra loads it unchanged from a local directory in the public drafter's place. On that route, which drafts one block of 8 tokens, it serves at the public drafter's speed: 46.1 tok/s on code against 46.2 and 46.4 for the public drafter's two launches, and 37.5 on chat against 37.3 and 37.4. Over six round shapes on that host it needs as many verify rounds as the public drafter at the block of 8, on the chain and on the engine's 8-row tree (within 1%), and about 2% fewer at a block of 16, which one pass over 20 prompts does not resolve. Do not expect the gain above on MLX; it is measured on the CUDA tree, which this drafter was fine-tuned for. Task quality was not checked there, M5 was not run, and oMLX, dflash-mlx and mlx-lm were not tried. Record
Training
- Parent:
z-lab/Qwen3.8-27B-DFlash2(model.safetensorssha25667fc76d68dc5a9415511a4f394ef744d67510cd20e93b37cc2cc7d28e4bab65c), every tensor trained, one epoch over 18,000 conversations (1,125 steps), learning rate 5e-5 held constant after warm-up, 16-token blocks, seed 42. - Trainer: SpecForge at
01ee4bd, its DFlash2 objective with the strict top-16 selector term, with the AX Tendem patchspecforge-tree-loss.patchapplied and its tree term off (the default; two seeds with the term on did not agree on a gain). Configuration and tools are inbackends/sglang/training/tendem/of the AX Tendem repository;provenance.jsonrecords the data and patch digests. - Text: 18,000 conversations whose prompts come from UltraChat (8,712, MIT), Magicoder Evol-Instruct-110K (4,781, Apache-2.0) and GSM8K train (4,507, MIT), and whose answers are the target's own: the NVFP4 pack at temperature 0 with thinking off and at most 1,024 tokens. CodeAlpaca-20k prompts, which the earlier fine-tunes used, are excluded because that dataset's source repository carries a CC BY-NC 4.0 data licence.
- Overlap with the evaluation prompts (
receipts/release-training-overlap.json): no prompt of either holdout and no problem statement of the quality sets is in the training text. Counting prompts that share at least half of their 5-word shingles with one training prompt: none of the second holdout (largest share 0.33), 2 of the first holdout's 200, 14 of 164 HumanEval statements, 5 of 257 MBPP statements and none of the 500 GSM8K questions. The closest training prompts are all from Magicoder Evol-Instruct. Their answers in the training text are the target's, and at serving time the target decides every token, so this can raise the drafter's speed on those problems and not the answers; the speed headline uses the second holdout for that reason.
What was not measured
Sampling, long contexts, tool calls, thinking mode, other target packs or quantizations, other GPUs, vLLM or an unmodified SGLang, and chat quality. Two training seeds of the recipe were run; the difference between them is reported above and is of the same order as the gain's interval. The primary target of AX Tendem is MLX on Apple M5; the only MLX result is the development check under Apple silicon.
Files
| File | SHA-256 |
|---|---|
model.safetensors |
d6d670c849e63e2fc95391fe6051df55e0a6ff61af2163aff6f910adcf5bb6ef |
config.json |
873e3556509b0da06e29654ba00d4944888d4b5e8a33afde25f7eb27d321e980 (the public drafter's, unchanged) |
SHA256SUMS lists every file. receipts/ holds the measurement records the tables are made from,
each with a scope line stating the host and what it does not show. provenance.json and the
training configuration record how the weights were made.
After publication the repository was downloaded without credentials on one of the hosts, checked
against SHA256SUMS and served from that copy: all 200 requests of the second holdout returned
the tokens of the measured weights (receipts/release-hub-smoke.json).
Licence
Apache-2.0. This is a modified copy of the DFlash 2 drafter for Qwen 3.8 27B, which its authors
publish under Apache-2.0; see NOTICE. The target model, Qwen 3.8 27B, is not part of this
repository.
- Downloads last month
- 813