Dataset Viewer
Auto-converted to Parquet Duplicate
weights
large_stringclasses
4 values
history
int64
0
10
canonical_order
bool
2 classes
episode_id
large_stringclasses
80 values
requests_cache_path
int64
1
40
requests_recompute_path
int64
1
33
diverged
bool
2 classes
first_divergent_request
int64
0
21
⌀
first_divergent_token
int64
0
85
⌀
divergence_kind
large_stringclasses
1 value
F16
0
true
multi_turn_base_0
21
21
false
null
null
null
F16
0
true
multi_turn_base_1
8
8
false
null
null
null
F16
0
true
multi_turn_base_2
21
21
false
null
null
null
F16
0
true
multi_turn_base_3
4
4
false
null
null
null
F16
0
true
multi_turn_base_4
10
8
true
5
0
token
F16
0
true
multi_turn_base_5
10
9
true
4
3
token
F16
0
true
multi_turn_base_6
21
21
true
15
4
token
F16
0
true
multi_turn_base_7
21
21
false
null
null
null
F16
0
true
multi_turn_base_8
8
8
true
5
2
token
F16
0
true
multi_turn_base_9
6
6
true
2
24
token
F16
0
true
multi_turn_base_10
10
10
false
null
null
null
F16
0
true
multi_turn_base_11
5
5
false
null
null
null
F16
0
true
multi_turn_base_12
21
21
false
null
null
null
F16
0
true
multi_turn_base_13
4
4
false
null
null
null
F16
0
true
multi_turn_base_14
8
8
true
1
10
token
F16
0
true
multi_turn_base_15
13
13
true
10
45
token
F16
0
true
multi_turn_base_16
21
21
false
null
null
null
F16
0
true
multi_turn_base_17
21
21
false
null
null
null
F16
0
true
multi_turn_base_18
14
14
false
null
null
null
F16
0
true
multi_turn_base_19
7
25
true
1
0
token
F16
0
true
multi_turn_base_20
21
21
false
null
null
null
F16
0
true
multi_turn_base_21
21
21
false
null
null
null
F16
0
true
multi_turn_base_22
8
11
true
1
0
token
F16
0
true
multi_turn_base_23
8
8
false
null
null
null
F16
0
true
multi_turn_base_24
33
26
true
14
0
token
F16
0
true
multi_turn_base_25
8
8
false
null
null
null
F16
0
true
multi_turn_base_26
21
21
false
null
null
null
F16
0
true
multi_turn_base_27
15
15
false
null
null
null
F16
0
true
multi_turn_base_28
6
6
false
null
null
null
F16
0
true
multi_turn_base_29
6
6
false
null
null
null
F16
0
true
multi_turn_base_30
5
5
true
3
34
token
F16
0
true
multi_turn_base_31
21
21
false
null
null
null
F16
0
true
multi_turn_base_32
4
4
false
null
null
null
F16
0
true
multi_turn_base_33
10
10
true
6
18
token
F16
0
true
multi_turn_base_34
23
23
false
null
null
null
F16
0
true
multi_turn_base_35
8
8
false
null
null
null
F16
0
true
multi_turn_base_36
7
25
true
1
17
token
F16
0
true
multi_turn_base_37
21
21
false
null
null
null
F16
0
true
multi_turn_base_38
5
5
false
null
null
null
F16
0
true
multi_turn_base_39
15
14
true
8
23
token
F16
0
true
multi_turn_base_40
21
21
false
null
null
null
F16
0
true
multi_turn_base_41
21
21
true
1
32
token
F16
0
true
multi_turn_base_42
21
21
false
null
null
null
F16
0
true
multi_turn_base_43
8
8
false
null
null
null
F16
0
true
multi_turn_base_44
21
21
true
2
1
token
F16
0
true
multi_turn_base_45
4
5
true
3
0
token
F16
0
true
multi_turn_base_46
3
3
false
null
null
null
F16
0
true
multi_turn_base_47
8
23
true
3
1
token
F16
0
true
multi_turn_base_48
21
21
false
null
null
null
F16
0
true
multi_turn_base_49
8
8
false
null
null
null
F16
0
true
multi_turn_base_50
2
2
false
null
null
null
F16
0
true
multi_turn_base_51
8
8
false
null
null
null
F16
0
true
multi_turn_base_52
21
21
false
null
null
null
F16
0
true
multi_turn_base_53
8
8
true
7
0
token
F16
0
true
multi_turn_base_54
8
8
false
null
null
null
F16
0
true
multi_turn_base_55
13
13
true
10
3
token
F16
0
true
multi_turn_base_56
8
8
false
null
null
null
F16
0
true
multi_turn_base_57
3
3
false
null
null
null
F16
0
true
multi_turn_base_58
8
8
false
null
null
null
F16
0
true
multi_turn_base_59
10
10
true
3
35
token
F16
0
true
multi_turn_base_60
16
16
true
15
15
token
F16
0
true
multi_turn_base_61
26
18
true
4
0
token
F16
0
true
multi_turn_base_62
9
9
true
6
9
token
F16
0
true
multi_turn_base_63
9
9
true
6
14
token
F16
0
true
multi_turn_base_64
8
8
true
4
0
token
F16
0
true
multi_turn_base_65
21
8
true
0
17
token
F16
0
true
multi_turn_base_66
21
21
true
3
16
token
F16
0
true
multi_turn_base_67
6
6
false
null
null
null
F16
0
true
multi_turn_base_68
9
9
false
null
null
null
F16
0
true
multi_turn_base_69
9
9
false
null
null
null
F16
0
true
multi_turn_base_70
19
19
true
16
54
token
F16
0
true
multi_turn_base_71
13
13
false
null
null
null
F16
0
true
multi_turn_base_72
12
12
true
9
13
token
F16
0
true
multi_turn_base_73
8
8
false
null
null
null
F16
0
true
multi_turn_base_74
4
4
false
null
null
null
F16
0
true
multi_turn_base_75
8
8
false
null
null
null
F16
0
true
multi_turn_base_76
6
6
false
null
null
null
F16
0
true
multi_turn_base_77
21
21
false
null
null
null
F16
0
true
multi_turn_base_78
8
4
true
1
0
token
F16
0
true
multi_turn_base_79
7
7
true
6
8
token
F16
1
false
multi_turn_base_0
21
21
false
null
null
null
F16
1
false
multi_turn_base_1
8
8
false
null
null
null
F16
1
false
multi_turn_base_2
21
21
false
null
null
null
F16
1
false
multi_turn_base_3
4
4
false
null
null
null
F16
1
false
multi_turn_base_4
10
8
true
5
0
token
F16
1
false
multi_turn_base_5
10
9
true
6
5
token
F16
1
false
multi_turn_base_6
21
21
true
15
4
token
F16
1
false
multi_turn_base_7
21
21
false
null
null
null
F16
1
false
multi_turn_base_8
8
8
true
5
2
token
F16
1
false
multi_turn_base_9
6
6
false
null
null
null
F16
1
false
multi_turn_base_10
10
10
false
null
null
null
F16
1
false
multi_turn_base_11
5
5
false
null
null
null
F16
1
false
multi_turn_base_12
21
21
false
null
null
null
F16
1
false
multi_turn_base_13
4
4
false
null
null
null
F16
1
false
multi_turn_base_14
8
8
true
1
10
token
F16
1
false
multi_turn_base_15
13
13
true
10
45
token
F16
1
false
multi_turn_base_16
21
21
false
null
null
null
F16
1
false
multi_turn_base_17
21
21
false
null
null
null
F16
1
false
multi_turn_base_18
14
14
false
null
null
null
F16
1
false
multi_turn_base_19
7
25
true
1
0
token
End of preview. Expand in Data Studio

Same Request, Different Answer: prefix-cache divergence in LLM serving

This dataset holds the measurements behind the paper Same Request, Different Answer: Quantization Amplifies Cache-Induced Divergence in LLM Serving (Aditi Patodiya, IEEE Access, 2026).

Built from repository commit afcef55. The data are the same as in the archived release.

What was measured

Serving engines reuse the cached key-value state of a shared prompt prefix. The study asks whether a request served from that cache gives the same answer as the same request computed from scratch. Everything else is held fixed: model, greedy decoding, seed, one slot and one request at a time.

The manipulated variable is prefix reuse (llama.cpp's per-request cache_prompt flag). llama.cpp's separate server-level prompt cache (--cache-ram) is off throughout the sweep.

Main setup: Qwen2.5-7B-Instruct on llama.cpp (release b10434, commit 7e4c0a9) on an RTX 4090 with CUDA 12.6. The key-value cache is in 16-bit floating point in every format. The workload is the first 80 episodes of the Berkeley Function Calling Leaderboard multi-turn base category, served in four weight formats (F16, Q8_0, Q4_K_M, Q3_K_M). Each format ran under the canonical episode order and ten random orders (server histories), each on a fresh server.

Main results, which the tables below reproduce:

Weights Episodes whose trajectory differs between cache hit and recompute (mean of ten histories)
F16 37.4%
Q8_0 59.5%
Q4_K_M 82.5%
Q3_K_M 77.1%

In the sweep, the reference pass with prefix reuse off ran under two episode orders for each format and matched itself in every token and log-probability.

Tables

sweep_episodes (3,520 rows)

One row per weight format, server history and episode. Each pass with prefix reuse on is compared with the prefix-reuse-off reference pass of the same format under the canonical episode order.

Column Meaning
weights F16, Q8_0, Q4_K_M or Q3_K_M
history 0 is the canonical episode order; 1 to 10 are random orders
canonical_order true when history is 0
episode_id BFCL multi-turn episode id
requests_cache_path, requests_recompute_path requests the episode made on each path
diverged the two paths produced different trajectories
first_divergent_request index of the first request that differed (empty when not diverged)
first_divergent_token index of the first differing token in that request (empty when not diverged)
divergence_kind token (same prompt, different output; every divergent episode here is of this kind), or empty when not diverged

The headline rate for a format is the mean over histories 1 to 10 of the share of episodes with diverged true.

margins (51,520 rows)

The top-two logit margin at every shared position of a cache-hit request, canonical history only. A shared position is one where both paths saw the same prompt and the same preceding tokens. The walk of an episode stops at its first flip, at a prompt mismatch, or at a request whose log-probabilities merge tokens split inside a UTF-8 character. Each divergent episode therefore contributes exactly one row with flipped true.

Column Meaning
weights weight format
episode_id episode
margin_recompute top-two logit margin on the recompute path
margin_cache top-two logit margin on the cache path
abs_margin_change absolute difference of the two margins
flipped the emitted token differed at this position

At positions where the token did not flip, the median abs_margin_change is 0.028 logits at F16, 0.10 at Q8_0, 0.16 at Q4_K_M and 0.14 at Q3_K_M. Margins come from llama.cpp's reported top-five log-probabilities.

gsm8k_bridge (1,500 rows)

A single-turn check on GSM8K test items. Each item was sent four times: twice on the recompute path and twice as a cache hit. Every path repeated itself on every item. The bridge comes from the earlier grid, with llama.cpp's server-level prompt cache at its default (8192 MiB), not from the --cache-ram 0 sweep.

Column Meaning
model, weights, run configuration
item_idx GSM8K test item index
gold reference answer
recompute_answer, cache_hit_answer extracted final answers
recompute_correct, cache_hit_correct answer equals gold as a number
texts_identical the first recompute and first cache-hit responses were identical
recompute_truncated, cache_hit_truncated the response hit the token limit

Qwen2.5-7B at Q4_K_M appears in two runs: the 500-item run bridge-qwen7b-q4km-n500 extends the 200-item run bridge-lcpp-qwen7b-q4km and shares its items 0 to 199. Group by run, not by model and weights.

Answers are extracted with the paper's corrected extractor (analysis/reextract_bridge.py in the repository). The share of items with texts_identical false is 3.5% at F16, 44.5% at Q8_0, 41.5% at Q4_K_M (45.4% over 500 items), 48.0% at Q3_K_M and 48.0% for Qwen2.5-14B at Q4_K_M.

Raw logs

raw/ holds 58 per-request logs: the 54 the tables come from, and the second prefix-reuse-off pass of each format under a different episode order (results-revision/B2/*_order1), which matches the first in every token and log-probability. It also holds each GSM8K run's summary.json, the source of the gold answers. Checksums are in raw/SHA256SUMS.json, with paths relative to raw/.

Each line is one request with its prompt hash, latency and the full server response, including token ids, top log-probabilities and cached-token counts. Sweep lines carry episode_id and request_idx. GSM8K lines carry item_idx and pass: cold and cold2 are recompute passes, warm and warm2 are cache hits. Prompts are stored as hashes, not text. The server reports build b1-7e4c0a9 (a source build at release b10434), and the sweep logs carry the model alias repair. The F16 GSM8K log also keeps 67 records from an aborted first attempt; the table keys on item and pass, so the restarted run supersedes them.

The repository holds every other run of the study.

How the tables were built

build_hf_dataset.py, included in this dataset, derives all three tables with the study's own analysis code and stops if any value differs from the paper: the four sweep means, the seven fine margin bins at Q4_K_M, the four median margin changes, and the six GSM8K rates. Run it against a checkout of commit afcef55 with the repository's environment, for example python -I -B build_hf_dataset.py --artifact <checkout> --out <new folder>. It overwrites the folder given by --out.

Scope

The sweep uses one model (Qwen2.5-7B-Instruct) on one llama.cpp build and one GPU type; Qwen2.5-14B appears only in the GSM8K bridge. The study also observed path divergence on vLLM 0.11.0 but makes no claim there about quantization. Other engines, backends and models are not covered by these tables.

License

The measurements are released under CC BY 4.0, and build_hf_dataset.py under MIT, like the repository code. Episode ids, and the tasks the model output refers to, come from the Berkeley Function Calling Leaderboard (Apache 2.0). GSM8K items come from the GSM8K test set (MIT). Model outputs were generated by Qwen2.5-7B-Instruct and Qwen2.5-14B-Instruct, both released under Apache 2.0.

Citation

@article{patodiya2026samerequest,
  title   = {Same Request, Different Answer: Quantization Amplifies
             Cache-Induced Divergence in LLM Serving},
  author  = {Patodiya, Aditi},
  journal = {IEEE Access},
  year    = {2026},
  doi     = {10.1109/ACCESS.2026.3749922},
  url     = {https://doi.org/10.1109/ACCESS.2026.3749922}
}
Downloads last month
-

Paper for aditiPatodiya/cache-divergence-llm-serving