Skip to content

Turing

intutic.github.io • November 29, 2026

Storing an LLM's KV cache in 8 or 4 bits fits more tokens on a GPU, but on some models it silently breaks the output : vLLM's fp8 cache takes Qwen2.5-1.5B-Instruct from 57% to 2% on GSM8K. Turing Engine is an LLM inference server that finds the layers a low-bit cache would break, keeps them in full precision, and lets you measure what every KV-cache or quantization change costs on real models. It has HuggingFace parity tests on 16 model types, 4-bit GPTQ weights, EAGLE-3 speculative decoding, and OpenAI, Anthropic and Ollama APIs on one port, and runs on NVIDIA GPUs, Apple Silicon and CPUs. With Qwen2.5-1.5B on an NVIDIA L4, its int4 KV cache holds 2.4× as many tokens as a 16-bit cache in the same GPU memory, at +0.02 nats, and 4-bit decoding (the LM head in 4 bits too) is 1.09–1.34× faster than vLLM at batch sizes 1 to 64.

It loads HuggingFace checkpoints, llama.cpp GGUF files and its own 4-bit .tgate4 directories, and reproduces the HuggingFace model's logits when the KV cache is kept in the model's dtype. The KV cache defaults to int8 on CUDA (+0.003 nats on Qwen2.5-1.5B) and to the model's dtype elsewhere; every other lossy option (int4 or fp8 KV, Quest page selection, 4-bit weights, activation sparsity) is opt-in.

Then point any OpenAI, Anthropic or Ollama client at , or install the LangChain or LlamaIndex client, langchain-turing or llama-index-llms-turing . More in the quickstart , serving reference and integrations .

What it is good for ¶

Low-bit KV caches that stay correct without settings. At startup Turing finds the layers int8, fp8 or int4 storage damages and keeps them in the model's dtype. On Qwen2.5-1.5B-Instruct its int8, fp8 and int4 caches pass every pass-key retrieval to 32K and keep GSM8K within 5 points of bf16, where vLLM's default fp8 and its per-token int4 caches drop to 0.6–2.4% unless layer 0 is excluded by hand ( benchmarks §2 ).

Measured correctness. HuggingFace parity for 16 model types in the tests, 13 of them also on real checkpoints; 13 real GGUF files agree with llama.cpp ( models & hardware ).

A CPU backend on llama.cpp ( turing serve --backend libllama ): GGUF models on CPUs and Apple GPUs behind the same APIs, including MoE models larger than RAM ( CPU backend ).

Evals that run any idea against real models : KV and weight quality ( scripts/eval_kv_quality.py ), GSM8K and pass-key retrieval through the engine, and head-to-head benchmarks against vLLM and llama.cpp.

Experimental components with results on real models , including the ones that did not work ( experimental components ).

A production server. It has been measured against vLLM on one NVIDIA L4 with models of 0.4B to 8B parameters ( comparison ):

Ahead: at 4 bits with its default 4-bit LM head (1.09–1.34×), at 16K-token prompts in fp16 (1.06–1.40×), on the first token of a lone prompt, and in cold start.

Level or a little ahead: fp16 (101–103%) and an EAGLE-3 draft head (101.0–102.4% in 13 of 15 cells, the other two within the spread of vLLM's own runs).

Within 1% either way: a 1-byte fp8 KV cache at 16K tokens (99.0–101.3%).

Behind: up to 3% with an int8 KV cache at 16K tokens, up to 1% on a 4-bit MoE model with its LM head in fp16 (level when converted with --symmetric ), and 3% on OLMoE in bf16 at batch 32.

For production serving (multi-GPU, larger models, a longer track record) use vLLM, SGLang or TensorRT-LLM; on a laptop, llama.cpp or Ollama.