Local & Offline
~9 min readUpdated: November 2026

RTAQ: Reasoning-Termination-Aware 2-Bit MoE Quantization

RTAQ Reasoning Termination Aware MoE Quantization in Smoke Monkey

RTAQ (Reasoning-Termination-Aware Quantization, arXiv:2611.37751) solves 2-bit accuracy collapse in Mixture-of-Experts reasoning models. Up to 47% of GPTQ errors come from unclosed reasoning traces failing to emit `</think>`, governed by roughly 2% of routed experts. By protecting termination experts in a knapsack bit budget with DP-optimal codebooks, RTAQ reaches 2.022-bit average width while retaining 94–98% BF16 accuracy, shrinking expert VRAM 6.3x (64.4 GB to 10.3 GB), and hitting 4,880 tok/s.

Technical Review: Smoke Monkey Core Architecture Team
Tested on Node.js 18+ & BunTypeScript 5.x
Quick Answer & Executive Definition

RTAQ: Reasoning-Termination-Aware 2-Bit MoE Quantization: RTAQ (Reasoning-Termination-Aware Quantization, arXiv:2611.37751) solves 2-bit accuracy collapse in Mixture-of-Experts reasoning models. Up to 47% of GPTQ errors come from unclosed reasoning traces failing to emit `</think>`, governed by roughly 2% of routed experts. By protecting termination experts in a knapsack bit budget with DP-optimal codebooks, RTAQ reaches 2.022-bit average width while retaining 94–98% BF16 accuracy, shrinking expert VRAM 6.3x (64.4 GB to 10.3 GB), and hitting 4,880 tok/s. Designed as a zero-dependency, open-source TypeScript architecture under the MIT License with native Model Context Protocol (MCP) support and deterministic phase state machines.

Key Architectural Takeaways
Quick Implementation Examplertaq-moe-reasoning-agent.ts
rtaq-moe-reasoning-agent.tstypescript
import { createAgent } from '@smoke-monkey/harness';
const localReasoningAgent = createAgent({
agentId: 'rtaq-2bit-moe-engineer',
provider: 'vllm',
model: 'Qwen3.6-35B-A3B-RTAQ-2.02bit',
workspacePath: process.cwd(),
permissions: {
read_file: 'allow',
write_file: 'allow',
run_command: 'ask',
},
generationConfig: {
maxTokens: 16384,
stopTokens: ['</think>'],
temperature: 0.2,
},
});
async function solveArchitectureTask() {
const result = await localReasoningAgent.run(
'Analyze circular dependencies across src/core/ and propose a non-breaking refactor plan.'
);
console.log('MoE Reasoning Output:', result.summary);
}
solveArchitectureTask().catch(console.error);
Video Guides

Watch: Related Video Guides

A Visual Guide to Mixture of Experts (MoE) in LLMs

What is Mixture of Experts?

What Is RTAQ? The Hidden Role of Termination-Aware Experts

In sparse MoE architectures such as Qwen3.6-35B-A3B, over 97% of model parameters reside inside routed expert weights. Compressing those experts to ~2 bits enables single-GPU serving, yet uniform 2-bit PTQ collapses on AIME and GPQA-Diamond. RTAQ proves that collapse is rarely a knowledge failure: when quantized models successfully emit the closing </think> token, accuracy tracks BF16 closely; up to 47% of GPTQ errors stem from endless reasoning loops that never close.

Routing telemetry reveals that </think> prediction concentrates on a consistent ~2% subset of routed experts overlooked by global Fisher or Hessian norms. RTAQ locks those termination-aware experts at higher precision, allocates the remaining global 2.0-bit budget via knapsack optimization over DP-optimal scalar codebooks, and recalibrates outputs in under one second per expert.

RTAQ vs GPTQ, MC-MoE, GSQ & TileQ on Long-Horizon Reasoning

At an average of 2.022 bits across routed experts, RTAQ outperforms higher-bit competitors (2.125–2.358 bits) across Qwen3.6-35B-A3B and Nemotron-3-Nano-30B-A3B.

Model & QuantizerAvg BitsGSM8KAIME25AIME26 (Strict)GPQA-DiamondLCBAvg Score
Qwen3.6-35B-A3B (BF16)16.00096.891.191.182.377.687.85
RTAQ (Ours)2.02296.690.093.378.670.285.81
MC-MoE2.35896.388.985.671.972.383.07
GSQ2.12596.084.486.779.866.482.74
TileQ2.32095.282.286.773.749.477.24
GPTQ2.25095.780.081.171.250.175.79

Hardware profiling on a single GPU shows RTAQ shrinks routed-expert memory 6.3x (64.4 GB -> 10.3 GB), expands available KV-cache capacity 3.8x, speeds up MoE layers 4.0–4.3x at batch >= 16, and hits 3,182 tok/s (batch 48, 2.09x BF16) and 4,880 tok/s (batch 128, 1.92x BF16).

Calibrate With Reasoning-Termination Traces

Always include both reasoning-on (`openr1_math_verified`, `nemotron_math_v3`) and reasoning-off/anchor prompts in your 128-document calibration pack so termination experts receive accurate activation statistics.

Profiling Termination Experts & Knapsack Bit Allocation

To reproduce RTAQ's termination-aware protection before exporting a 2-bit MoE checkpoint, log expert router selections specifically at the </think> token position across a 128-sample mixed calibration set.

python
import torch

def identify_termination_experts(router_logits_at_think_end: torch.Tensor, top_k: int = 8, threshold: float = 0.02):
    """Flag routed experts disproportionately triggered when emitting </think>."""
    # router_logits_at_think_end: [num_layers, num_samples, num_experts]
    probs = torch.softmax(router_logits_at_think_end, dim=-1)
    topk_idx = probs.topk(top_k, dim=-1).indices
    num_layers, _, num_experts = probs.shape
    freq = torch.zeros((num_layers, num_experts), dtype=torch.float32)
    for l in range(num_layers):
        freq[l].scatter_add_(0, topk_idx[l].reshape(-1), torch.ones(topk_idx[l].numel()))
    freq /= router_logits_at_think_end.shape[1]
    # Protect top ~2% termination-critical experts at >= 4-bit precision
    k_protect = max(1, int(num_experts * threshold))
    return freq.topk(k_protect, dim=-1).indices

Running High-Concurrency Local Reasoning Agents in Smoke Monkey

Because 2-bit RTAQ frees 3.8x more KV-cache headroom on a single GPU while preventing </think> truncation failures, Smoke Monkey Harness can run long-context repository reasoning loops (16K–64K tokens) concurrently across multiple local agent threads without falling into infinite thought-loop token exhaustion.

Google Search Questions & Answers

Frequently Asked Questions

Q:Why do 2-bit quantized reasoning MoE models get stuck in infinite loops?

RTAQ shows that ~2% of routed experts specifically control emission of the `</think>` token. Standard sensitivity metrics overlook them, causing aggressive quantization to suppress `</think>` and account for up to 47% of GPTQ errors.

Q:How much VRAM does Qwen3.6-35B-A3B need with RTAQ?

RTAQ compresses routed-expert weights from 64.4 GB in BF16 down to 10.3 GB (a 6.3x reduction), allowing the model to serve on a single GPU with 3.8x larger KV-cache capacity.

Q:How long does RTAQ's grid-preserving recalibration take?

RTAQ's third stage reassigns quantized codes with GPTQ-style error compensation and rescales expert outputs in under 1 second per expert.

Q:Does RTAQ hurt non-reasoning or standard coding tasks?

No. RTAQ retains 96.6% on GSM8K and 70.2% on LiveCodeBench at 2.022 bits, outperforming GPTQ (50.1% LCB at 2.250 bits) and TileQ (49.4% LCB at 2.320 bits).

Related Alternatives & Comparisons

Related Architecture Guides

View all guides

Build with Smoke Monkey Harness

Zero dependencies. 24 built-in tools. Human-in-the-loop safety. 100% open source under the MIT License.

npm install smoke-monkey-harness