This repo strives to provide the highest quality quant for specific target sizes.
Targets 192 GiB of VRAM: 2x RTX Pro 6000 or 8x RTX 3090
Very long-context. It supports 524K context with unquantized FP16 KV-cache or 1M context with 8-bit KV-cache
Highlights of the quant
EXL3 quantization strategy is state-of-the-art. It uses Hadamard rotations (predating Turboquant by 2 years, including for KV-cache quantization) to spread value spikes on random directions to ease quantization + Trellis / lattice codebooks which have been extremely useful for video compression/quantization (coming from rate-distortion theory).
TabbyAPI (frontend) / ExllamaV3 (backend) support PagedAttention, true continuous batching and ragged concurrent requests like vLLM and SGLang.
[!TIP]
💡 This is unlike llama.cpp / ik-llama.cpp / ollama which use fixed slots of size context / preconfigured_concurrency so for a base 262144 context, with a concurrency of 2, only 131072 token can be used by a single user even if no other query is in flight.
In theory, tensor parallelism is possible (it is used for my GLM-4.7 quant), however sharding Gated Delta Nets (Qwen3.5 linear attention) is still pending.
Quantization makes sure that all experts are activated. (The alternative being a large and extremely diverse dataset to ensure comprehensive activation ranges of all experts)
💡**[Click me!]** Visual showcase of why ensuring quantization of all MoE experts is important
Historically TabbyAPI didn't support reasoning and tool-calling, this has been solved as of Apr 12, 2026 commit #32eed618. The quant can be configured with the following config.yaml for proper reasoning and tool-calling.
config.yml (Only what is modified from default)
yml
1# Options for model overrides and loading2# Please read the comments to understand how arguments are handled3# between initial and API loads4model:5# An initial model to load.6# Make sure the model is located in the model directory!7# REQUIRED: This must be filled out to load a model on startup.8model_name:"Qwen3.5-397B-A17B"910# Max sequence length (default: min(max_position_embeddings, cache_size)).11# Set to -1 to fetch from the model's config.json12# max_seq_len: -113# max_seq_len: 104857614max_seq_len:5242881516# Size of the key/value cache to allocate, in tokens (default: 4096).17# Must be a multiple of 256.18# ExllamaV2 note: On AMD GPUs and NVIDIA GPUs older than Ampere, this value19# is ignored. Please use max_seq_len20# cache_size: 131072021cache_size:6553602223# Enable different cache modes for VRAM savings (default: FP16).24# Possible values for exllamav2: 'FP16', 'Q8', 'Q6', 'Q4'.25# For exllamav3, specify the pair k_bits,v_bits where k_bits and v_bits are integers from 2-8 (i.e. 8,8).26cache_mode: FP16 # For 524288 context / 655360 cache27# cache_mode: 8,8 # For 1M context,28# cache_mode: 6,5 # For large cache, dequantizing can be costly in terms of tok/s2930# Load model with tensor parallelism.31# Falls back to autosplit if GPU split isn't provided.32# This ignores the gpu_split_auto value.33# tensor_parallel: true34tensor_parallel:false3536# Reserve VRAM used for autosplit loading (default: 96 MB on GPU 0).37# Represented as an array of MB per GPU.38autosplit_reserve:[1024]3940# Regarding rope_scaling, the model defaults to 0.2541# in config.json so this covers 1M context natively.4243# Chunk size for prompt ingestion (default: 2048).44# A lower value reduces VRAM usage but decreases ingestion speed.45# NOTE: Effects vary depending on the model.46# An ideal value is between 512 and 4096.47chunk_size:40964849# Enables vision support if the model supports it. (default: False)50vision:true5152# Enable reasoning parser (default: False).53# Do NOT enable this if the model is not a reasoning model (e.g. deepseek-r1 series)54reasoning:true5556# Tool format, e.g. 'qwen3_coder'. See docs for supported formats. If left blank,57# tool calls from the model will not be parsed by the server.58tool_format: qwen3_coder
5960# Options for Sampling61sampling:62# Select a sampler override preset (default: None).63# Find this in the sampler-overrides folder.64# This overrides default fallbacks for sampler values that are passed to the API.65# NOTE: safe_defaults is noob friendly and provides fallbacks for frontends that don't send sampling parameters.66# Remove this for any advanced usage.67# override_preset: safe_defaults68override_preset: Qwen3.5
6970# Qwen3.5.yml contains71# -----------72# temperature:73# override: 0.774# force: false75# top_p:76# override: 0.877# force: false78# top_k:79# override: 2080# force: false
The Qwen3.5.yml sampling file has the official recommended settings and is expected in the subdirectory SAMPLERS_PATH="${DIR}/sampler_overrides" from the launch_script
via the command TMPDIR=$HOME/AI/tmpdir/tabbyAPI-build podman build -t tabby-202604-cu128 -f Dockerfile-tabby-202604
TabbyAPI/Exllamav3 Dockerfile
Dockerfile
1# Use an official CUDA runtime with Ubuntu as a parent image
2FROM nvidia/cuda:12.8.1-runtime-ubuntu24.04
34# Install system dependencies
5RUN apt-get update && apt-get install -y --no-install-recommends \
6 build-essential \
7 curl \
8 ca-certificates \
9 python3.12 \
10 python3-pip \
11 python3.12-venv \
12 python3.12-dev \
13 git \
14 && rm -rf /var/lib/apt/lists/*
1516# Create a virtual environment
17RUN python3 -m venv /opt/venv
1819# Activate the venv and set the PATH
20ENV PATH="/opt/venv/bin:$PATH"
2122# Upgrade pip and install uv
23RUN pip install --no-cache-dir --upgrade pip
2425# Set the working directory in the container
26WORKDIR /app
2728# Clone tabbyAPI repository.
29RUN git clone https://github.com/theroyallab/tabbyAPI.git /app
3031# Install packages specified in pyproject.toml cu12, extras
32# RUN pip install --no-cache-dir .[cu12,extras]
33RUN pip install --no-cache-dir .[cu12]
3435# Triton needs `apt get install python3.12-dev` for <Python.h>
36RUN pip install triton flash-linear-attention
3738# Impossible to compile by itself, if fails in PyTorch cpp_extension.py
39# with a 404 error
40# similar to https://github.com/Dao-AILab/causal-conv1d/issues/4
41RUN pip install https://github.com/Dao-AILab/causal-conv1d/releases/download/v1.6.1.post4/causal_conv1d-1.6.1+cu12torch2.9cxx11abiTRUE-cp312-cp312-linux_x86_64.whl
4243# Make port 5000 available to the world outside this container
44EXPOSE 5000
4546# Set the entry point
47ENTRYPOINT ["python3"]
4849# Run main.py when the container launches
50CMD ["main.py"]
And of course @turboderp for the amazing library, especially the tooling around quantization and quality measurement.
KL-divergence / quant quality
This has been measured with exllamav3 evals/model_diff which by default (-r 100) evaluates on 100 samples of 2048 tokens from wikitext2 dataset.
I reuse the figures from Neurosenko and cpral's quant for other quants and manually confirmed that their 3bpw and 3.536bpw matches my own manual measurements.
Unified Vision-Language Foundation: Early fusion training on multimodal tokens achieves cross-generational parity with Qwen3 and outperforms Qwen3-VL models across reasoning, coding, agents, and visual understanding benchmarks.
Efficient Hybrid Architecture: Gated Delta Networks combined with sparse Mixture-of-Experts deliver high-throughput inference with minimal latency and cost overhead.
Scalable RL Generalization: Reinforcement learning scaled across million-agent environments with progressively complex task distributions for robust real-world adaptability.
Global Linguistic Coverage: Expanded support to 201 languages and dialects, enabling inclusive, worldwide deployment with nuanced cultural and regional understanding.
Next-Generation Training Infrastructure: Near-100% multimodal training efficiency compared to text-only training and asynchronous RL frameworks supporting massive-scale agent scaffolds and environment orchestration.
Benchmark Results
For more details, please refer to our blog post Qwen3.5.
Model Overview
Type: Causal Language Model with Vision Encoder
Training Stage: Pre-training & Post-training
Language Model
Number of Parameters: 397B in total and 17B activated
Number of Linear Attention Heads: 64 for V and 16 for QK
Head Dimension: 128
Gated Attention:
Number of Attention Heads: 32 for Q and 2 for KV
Head Dimension: 256
Rotary Position Embedding Dimension: 64
Mixture Of Experts
Number of Experts: 512
Number of Activated Experts: 10 Routed + 1 Shared
Expert Intermediate Dimension: 1024
LM Output: 248320 (Padded)
MTP: trained with multi-steps
Context Length: 262,144 natively and extensible up to 1,010,000 tokens.
Benchmark Results
Language
GPT5.2
Claude 4.5 Opus
Gemini-3 Pro
Qwen3-Max-Thinking
K2.5-1T-A32B
Qwen3.5-397B-A17B
Knowledge
MMLU-Pro
87.4
89.5
89.8
85.7
87.1
87.8
MMLU-Redux
95.0
95.6
95.9
92.8
94.5
94.9
SuperGPQA
67.9
70.6
74.0
67.3
69.2
70.4
C-Eval
90.5
92.2
93.4
93.7
94.0
93.0
Instruction Following
IFEval
94.8
90.9
93.5
93.4
93.9
92.6
IFBench
75.4
58.0
70.4
70.9
70.2
76.5
MultiChallenge
57.9
54.2
64.2
63.3
62.7
67.6
Long Context
AA-LCR
72.7
74.0
70.7
68.7
70.0
68.7
LongBench v2
54.5
64.4
68.2
60.6
61.0
63.2
STEM
GPQA
92.4
87.0
91.9
87.4
87.6
88.4
HLE
35.5
30.8
37.5
30.2
30.1
28.7
HLE-Verified¹
43.3
38.8
48
37.6
--
37.6
Reasoning
LiveCodeBench v6
87.7
84.8
90.7
85.9
85.0
83.6
HMMT Feb 25
99.4
92.9
97.3
98.0
95.4
94.8
HMMT Nov 25
100
93.3
93.3
94.7
91.1
92.7
IMOAnswerBench
86.3
84.0
83.3
83.9
81.8
80.9
AIME26
96.7
93.3
90.6
93.3
93.3
91.3
General Agent
BFCL-V4
63.1
77.5
72.5
67.7
68.3
72.9
TAU2-Bench
87.1
91.6
85.4
84.6
77.0
86.7
VITA-Bench
38.2
56.3
51.6
40.9
41.9
49.7
DeepPlanning
44.6
33.9
23.3
28.7
14.5
34.3
Tool Decathlon
43.8
43.5
36.4
18.8
27.8
38.3
MCP-Mark
57.5
42.3
53.9
33.5
29.5
46.1
Search Agent³
HLE w/ tool
45.5
43.4
45.8
49.8
50.2
48.3
BrowseComp
65.8
67.8
59.2
53.9
--/74.9
69.0/78.6
BrowseComp-zh
76.1
62.4
66.8
60.9
--
70.3
WideSearch
76.8
76.4
68.0
57.9
72.7
74.0
Seal-0
45.0
47.7
45.5
46.9
57.4
46.9
Multilingualism
MMMLU
89.5
90.1
90.6
84.4
86.0
88.5
MMLU-ProX
83.7
85.7
87.7
78.5
82.3
84.7
NOVA-63
54.6
56.7
56.7
54.2
56.0
59.1
INCLUDE
87.5
86.2
90.5
82.3
83.3
85.6
Global PIQA
90.9
91.6
93.2
86.0
89.3
89.8
PolyMATH
62.5
79.0
81.6
64.7
43.1
73.3
WMT24++
78.8
79.7
80.7
77.6
77.6
78.9
MAXIFE
88.4
79.2
87.5
84.0
72.8
88.2
Coding Agent
SWE-bench Verified
80.0
80.9
76.2
75.3
76.8
76.4
SWE-bench Multilingual
72.0
77.5
65.0
66.7
73.0
69.3
SecCodeBench
68.7
68.6
62.4
57.5
61.3
68.3
Terminal Bench 2
54.0
59.3
54.2
22.5
50.8
52.5
* HLE-Verified: a verified and revised version of Humanity’s Last Exam (HLE), accompanied by a transparent, component-wise verification protocol and a fine-grained error taxonomy. We open-source the dataset at https://huggingface.co/datasets/skylenage/HLE-Verified.
* TAU2-Bench: we follow the official setup except for the airline domain, where all models are evaluated by applying the fixes proposed in the Claude Opus 4.5 system card.
* MCPMark: GitHub MCP server uses v0.30.3 from api.githubcopilot.com; Playwright tool responses are truncated at 32k tokens.
* Search Agent: most search agents built on our model adopt a simple context-folding strategy(256k): once the cumulative Tool Response length reaches a preset threshold, earlier Tool Responses are pruned from the history to keep the context within limits.
* BrowseComp: we tested two strategies, simple context-folding achieved a score of 69.0, while using the same discard-all strategy as DeepSeek-V3.2 and Kimi K2.5 achieved 78.6.
* WideSearch: we use a 256k context window without any context management.
* MMLU-ProX: we report the averaged accuracy on 29 languages.
* WMT24++: a harder subset of WMT24 after difficulty labeling and rebalancing; we report the averaged scores on 55 languages using XCOMET-XXL.
* MAXIFE: we report the accuracy on English + multilingual original prompts (totally 23 settings).
* Empty cells (--) indicate scores not yet available or not applicable.
Vision Language
GPT5.2
Claude 4.5 Opus
Gemini-3 Pro
Qwen3-VL-235B-A22B
K2.5-1T-A32B
Qwen3.5-397B-A17B
STEM and Puzzle
MMMU
86.7
80.7
87.2
80.6
84.3
85.0
MMMU-Pro
79.5
70.6
81.0
69.3
78.5
79.0
MathVision
83.0
74.3
86.6
74.6
84.2
88.6
Mathvista(mini)
83.1
80.0
87.9
85.8
90.1
90.3
We-Math
79.0
70.0
86.9
74.8
84.7
87.9
DynaMath
86.8
79.7
85.1
82.8
84.4
86.3
ZEROBench
9
3
10
4
9
12
ZEROBench_sub
33.2
28.4
39.0
28.4
33.5
41.0
BabyVision
34.4
14.2
49.7
22.2
36.5
52.3/43.3
General VQA
RealWorldQA
83.3
77.0
83.3
81.3
81.0
83.9
MMStar
77.1
73.2
83.1
78.7
80.5
83.8
HallusionBench
65.2
64.1
68.6
66.7
69.8
71.4
MMBenchEN-DEV-v1.1
88.2
89.2
93.7
89.7
94.2
93.7
SimpleVQA
55.8
65.7
73.2
61.3
71.2
67.1
Text Recognition and Document Understanding
OmniDocBench1.5
85.7
87.7
88.5
84.5
88.8
90.8
CharXiv(RQ)
82.1
68.5
81.4
66.1
77.5
80.8
MMLongBench-Doc
--
61.9
60.5
56.2
58.5
61.5
CC-OCR
70.3
76.9
79.0
81.5
79.7
82.0
AI2D_TEST
92.2
87.7
94.1
89.2
90.8
93.9
OCRBench
80.7
85.8
90.4
87.5
92.3
93.1
Spatial Intelligence
ERQA
59.8
46.8
70.5
52.5
--
67.5
CountBench
91.9
90.6
97.3
93.7
94.1
97.2
RefCOCO(avg)
--
--
84.1
91.1
87.8
92.3
ODInW13
--
--
46.3
43.2
--
47.0
EmbSpatialBench
81.3
75.7
61.2
84.3
77.4
84.5
RefSpatialBench
--
--
65.5
69.9
--
73.6
LingoQA
68.8
78.8
72.8
66.8
68.2
81.6
V*
75.9
67.0
88.0
85.9
77.0
95.8/91.1
Hypersim
--
--
--
11.0
--
12.5
SUNRGBD
--
--
--
34.9
--
38.3
Nuscene
--
--
--
13.9
--
16.0
Video Understanding
VideoMME(w sub.)
86
77.6
88.4
83.8
87.4
87.5
VideoMME(w/o sub.)
85.8
81.4
87.7
79.0
83.2
83.7
VideoMMMU
85.9
84.4
87.6
80.0
86.6
84.7
MLVU (M-Avg)
85.6
81.7
83.0
83.8
85.0
86.7
MVBench
78.1
67.2
74.1
75.2
73.5
77.6
LVBench
73.7
57.3
76.2
63.6
75.9
75.5
MMVU
80.8
77.3
77.5
71.1
80.4
75.4
Visual Agent
ScreenSpot Pro
--
45.7
72.7
62.0
--
65.6
OSWorld-Verified
38.2
66.3
--
38.1
63.3
62.2
AndroidWorld
--
--
--
63.7
--
66.8
Medical VQA
SLAKE
76.9
76.4
81.3
54.7
81.6
79.9
PMC-VQA
58.9
59.9
62.3
41.2
63.3
64.2
MedXpertQA-MM
73.3
63.6
76.0
47.6
65.3
70.0
* MathVision:our model’s score is evaluated using a fixed prompt, e.g., “Please reason step by step, and put your final answer within \boxed{}.” For other models, we report the higher score between runs with and without the \boxed{} formatting.
* BabyVision: our model’s score is reported with CI (Code Interpreter) enabled; without CI, the result is 43.3.
* V*: our model’s score is reported with CI (Code Interpreter) enabled; without CI, the result is 91.1.
* Empty cells (--) indicate scores not yet available or not applicable.