SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2605.19660 · 2026

OScaR: The Occam's Razor for Extreme KV Cache Quantization in LLMs and Beyond

Wei Wu, Chao Zhang, Yifan Zhang, Hongxia Yang, Rui Yang, Jing Xiong, Yik-Chung Wu, Ngai Wong, Xialie Zhuang, Zunhai Su, Yulei Qian, Yuchen Xie, and 2 more

arXiv · PDF · Open in the Atlas

Code that ran

13 of 15 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (1 of them constructed an object rather than computing a result; 3 honoured the contract we drafted, 3 violated it and 1 has no contract verdict; 6 failures of our instrument; 2 no recorded run), measured 2026-11-23; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2605.19660.json · badge: /api/ran/2605.19660.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
ZunhaiSu/OScaR-KV-Quant community
Papers with Code archive
13 ran · 2 no recorded run
FunctionStatusWhere it lives
KVQuantizer Ran
ran on a synthesized input · constructed an object; no result was computed
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("1ffea55c1a42d726")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned an instance of its own class, KVQuantizer: the run constructed the object and did not call it, so no result was computed. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn.functional as F

torch.manual_seed(0)

ARGS = {
    "bits": 4,
    "groupsize": 2,
    "sym": True,
    "clip_ratio": 1.0,
    "per_channel": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type KVQuantizer — the run constructed an instance of its own class and did not call it; no shape is stated — the instrument coerces any output to an array; for a KVQuantizer output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
_hadamard_transform_pytorch Ran
ran; our contract draft was wrong, not the code
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("35333e487bbf174b")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# Create a small tensor with power-of-2 last dimension
# Shape: (2, 4) - batch size 2, dimension 4 (which is 2^2, a power of 2)
x = torch.randn(2, 4)

# Create arguments dict
ARGS = {
    "x": x,
    "scale": 1.0
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
_is_pow2 Ran
ran, violated the contract we drafted
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("562651e901c23867")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

def _is_pow2(n):
    """Check if n is a power of 2."""
    return n > 0 and n & n - 1 == 0

# The function takes a single parameter 'n' which should be a number
# It checks if n is a power of 2 using bitwise operations

ARGS = {
    "n": 8
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
_norm_factor_extract Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("9b414b96d293cc58")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create a small tensor with shape (B, nh, T, D)
# B=2 (batch), nh=3 (num heads), T=4 (sequence length), D=5 (embedding dim)
x = torch.randn(2, 3, 4, 5)

# Test with one of the valid methods
method = "norm_l2"

ARGS = {
    "x": x,
    "method": method
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
_norm_factor_restore Ran
ran, violated the contract we drafted
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("237295470464b4d1")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 4, dtype family float, shape (2, 3, 4, 5) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# Construct arguments for _norm_factor_restore
# x: (B, nh, T, D) quantized tensor
x = torch.randn(2, 3, 4, 5)  # B=2, nh=3, T=4, D=5

# norm_info: norm values returned by _norm_factor_extract
# Based on the function body, norm_info is multiplied with x
# So it should be broadcastable to x's shape
norm_info = torch.randn(2, 3, 4, 5)

# method: "norm_l2" | "norm_rsqrt" | "norm_max"
method = "norm_l2"

ARGS = {
    "x": x,
    "norm_info": norm_info,
    "method": method,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 4, dtype family float, shape (2, 3, 4, 5) — shape (2, 3, 4, 5) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
asym_dequant Ran
ran, honoured the contract we drafted
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("42da3755ec5f55fd")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# Create small tensors for asymmetric dequantization
# q: quantized values (typically integers or floats representing quantized data)
# scale: scaling factor for dequantization
# zero: zero point offset for asymmetric quantization

q = torch.tensor([[1, 2, 3, 4], [5, 6, 7, 8]], dtype=torch.float32)
scale = torch.tensor([[0.5, 0.5, 0.5, 0.5], [0.5, 0.5, 0.5, 0.5]], dtype=torch.float32)
zero = torch.tensor([[1, 1, 1, 1], [1, 1, 1, 1]], dtype=torch.float32)

ARGS = {
    "q": q,
    "scale": scale,
    "zero": zero,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
asym_quant Ran
ran; our contract draft was wrong, not the code
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("61f9d2c394b964e5")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small test tensors
x = torch.randn(2, 4)  # Input tensor to quantize
scale = torch.tensor([0.1, 0.2, 0.15, 0.25])  # Per-channel scales
zero = torch.tensor([5, 10, 8, 12])  # Per-channel zero points
maxq = 255  # Maximum quantization value

ARGS = {
    "x": x,
    "scale": scale,
    "zero": zero,
    "maxq": maxq,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
asym_quant_dequant Ran
ran; our contract draft was wrong, not the code
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("ee1603b6a317f6ef")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small test tensors
x = torch.randn(2, 4)
scale = torch.tensor([0.1])
zero = torch.tensor([10])
maxq = 255

ARGS = {
    "x": x,
    "scale": scale,
    "zero": zero,
    "maxq": maxq,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_minq_maxq Ran
ran, honoured the contract we drafted
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("c1d9e09a87dcf2ca")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 1, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Analyze the function:
# - bits: integer, used in 2 ** (bits - 1) - 1 and 2 ** bits - 1
# - sym: boolean, used in if condition

ARGS = {
    "bits": 8,
    "sym": True,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family int — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
is_pow2 Ran
ran, violated the contract we drafted
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("13baf68cd36c7523")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# The function is_pow2 takes a single parameter n and checks if it's a power of 2
# It uses bitwise operations: n > 0 and n & n - 1 == 0
# n should be an integer

ARGS = {
    "n": 8
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
sym_dequant Ran
ran, honoured the contract we drafted
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("be82a2289d043887")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

torch.manual_seed(0)

# sym_dequant takes two parameters: q and scale
# It performs: scale * q
# Both q and scale should be tensors or compatible for element-wise multiplication

q = torch.randn(2, 4)  # Small tensor: batch size 2, dimension 4
scale = torch.randn(2, 4)  # Small tensor with same shape for broadcasting

ARGS = {
    "q": q,
    "scale": scale,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
sym_quant Ran
ran; our contract draft was wrong, not the code
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("03c46353b2aef040")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 3, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create a small input tensor (batch_size=2, features=4)
x = torch.randn(2, 4)

# Create a scale tensor with same shape as x
scale = torch.ones(2, 4) * 0.1

# maxq is typically an integer representing the maximum quantization level
maxq = 127

ARGS = {
    "x": x,
    "scale": scale,
    "maxq": maxq,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 3, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
sym_quant_dequant Ran
ran; our contract draft was wrong, not the code
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("9fef7c2350080337")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned Tensor, ndim 2, dtype family float, shape (2, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch

torch.manual_seed(0)

# Create small test tensors
x = torch.randn(2, 4)  # Input tensor to quantize
scale = torch.tensor([0.1])  # Scale factor for quantization
maxq = 127  # Maximum quantization value (e.g., for int8)

ARGS = {
    "x": x,
    "scale": scale,
    "maxq": maxq
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 2, dtype family float, shape (2, 4) — shape (2, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
QuaRotKVCacheQuantizer Not yet run
unverified (harvested, no recorded run)
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("e782a01051c60864")
How it ran

no invocation recorded.

hadamard_rotation Not yet run
unverified (harvested, no recorded run)
ZunhaiSu/OScaR-KV-Quant/kv_cache_compression/quarot_utils.py
code served (permissive licence) · get_code("50add3266529eabf")
How it ran

no invocation recorded.

Also present in other papers' code

Of 15 samples lifted from this paper's linked repositories, 15 carry a function identity and 0 do not. Of the 15 distinct functions with an identity, 5 are also present in other papers whose code we hold (5 with at least one paper dated earlier, 0 the same month, 0 later) and 10 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
asym_dequant
brick of this paper's assembly: helper
2 other papers
2 dated earlier
2410.09426 (2024-10)
FLATQUANT: Flatness Matters for LLM Quantization
2511.04063 (2025-11)
DartQuant: Efficient Rotational Distribution Calibration for LLM Quantization
asym_quant
brick of this paper's assembly: helper
2 other papers
2 dated earlier
2404.00456 (2024-04)
QuaRot: Outlier-Free 4-Bit Inference in Rotated LLMs
2511.04063 (2025-11)
DartQuant: Efficient Rotational Distribution Calibration for LLM Quantization
asym_quant_dequant
brick of this paper's assembly: helper
1 other paper
1 dated earlier
2410.09426 (2024-10)
FLATQUANT: Flatness Matters for LLM Quantization
sym_dequant
brick of this paper's assembly: helper
1 other paper
1 dated earlier
2410.09426 (2024-10)
FLATQUANT: Flatness Matters for LLM Quantization
sym_quant_dequant
brick of this paper's assembly: helper
1 other paper
1 dated earlier
2410.09426 (2024-10)
FLATQUANT: Flatness Matters for LLM Quantization

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-23.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

The rapid advancement toward long-context reasoning and multi-modal intelligence has made the memory footprint of the Key-Value (KV) cache a dominant memory bottleneck for efficient deployment. Extreme low-bit quantization has emerged as a fundamental imperative to reclaim memory efficiency and sustain high-throughput inference. While the established per-channel quantization effectively accommodates intrinsic channel-wise outliers in Key tensors, its efficacy diminishes under extreme compression. In this work, we revisit the inherent limitations of the perchannel quantization paradigm from both empirical and theoretical perspectives. Our analysis identifies Token Norm Imbalance (TNI) as the primary bottleneck to quantization fidelity. We demonstrate that TNI systematically amplifies errors when shared quantization parameters are required to span token groups exhibiting substantial norm disparities. Instead of relying on intricate quantization pipelines (e.g., TurboQuant), we propose OScaR (Omni-Scaled Canalized Rotation), an accurate and lightweight KV cache compression framework for X-LLMs (i.e., textonly, multi-modal, and omni-modal LLMs). Advancing the per-channel paradigm, OScaR employs Canalized Rotation followed by Omni-Token Scaling to mitigate TNI-induced sequence-dimensional variance both effectively and efficiently, further supported by our optimized system design and CUDA kernels. Extensive evaluations across X-LLMs show that OScaR consistently outperforms existing methods and achieves near-lossless performance under INT2 quantization, establishing it as a robust, low-complexity, and universal framework that defines a new Pareto front. Compared with the BF16 FlashDecoding-v2 baseline, our OScaR implementation achieves a notable up to 3.0× speedup in decoding, reduces memory footprint by 5.3×, and increases throughput by 4.1×. The code for OScaR is publicly available at https://github.com/ZunhaiSu/OScaR-KV-Quant.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2605.19660")
get_code_for_paper("2605.19660")
have("2605.19660")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2605.19660.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2605.19660.svg)](https://syntology.ai/paper/2605.19660)

Connect an agent — have() is free.