quantprobe 1.11.1__tar.gz → 1.11.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. {quantprobe-1.11.1/quantprobe.egg-info → quantprobe-1.11.2}/PKG-INFO +2 -1
  2. {quantprobe-1.11.1 → quantprobe-1.11.2}/README.md +1 -0
  3. {quantprobe-1.11.1 → quantprobe-1.11.2}/pyproject.toml +1 -1
  4. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/__init__.py +1 -1
  5. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/optimize.py +11 -6
  6. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/plan.py +35 -19
  7. {quantprobe-1.11.1 → quantprobe-1.11.2/quantprobe.egg-info}/PKG-INFO +2 -1
  8. {quantprobe-1.11.1 → quantprobe-1.11.2}/LICENSE +0 -0
  9. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/__main__.py +0 -0
  10. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/auto.py +0 -0
  11. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/cli.py +0 -0
  12. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/dashboard.py +0 -0
  13. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/detect.py +0 -0
  14. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/fetch.py +0 -0
  15. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/probe.py +0 -0
  16. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/recipes/mistral-7b.json +0 -0
  17. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/recipes/qwen2.5-7b.json +0 -0
  18. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/recipes/qwen3-30b.json +0 -0
  19. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/recipes/qwen3.5-35b.json +0 -0
  20. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/recipes.py +0 -0
  21. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/runtime.py +0 -0
  22. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/spec.py +0 -0
  23. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe/target.py +0 -0
  24. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe.egg-info/SOURCES.txt +0 -0
  25. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe.egg-info/dependency_links.txt +0 -0
  26. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe.egg-info/entry_points.txt +0 -0
  27. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe.egg-info/requires.txt +0 -0
  28. {quantprobe-1.11.1 → quantprobe-1.11.2}/quantprobe.egg-info/top_level.txt +0 -0
  29. {quantprobe-1.11.1 → quantprobe-1.11.2}/setup.cfg +0 -0
  30. {quantprobe-1.11.1 → quantprobe-1.11.2}/tests/test_engine.py +0 -0
  31. {quantprobe-1.11.1 → quantprobe-1.11.2}/tests/test_evaluator.py +0 -0
  32. {quantprobe-1.11.1 → quantprobe-1.11.2}/tests/test_pipeline.py +0 -0
  33. {quantprobe-1.11.1 → quantprobe-1.11.2}/tests/test_transforms.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: quantprobe
3
- Version: 1.11.1
3
+ Version: 1.11.2
4
4
  Summary: Probe-then-quantize for LLMs: measure a model's fragility curve, plan bit/tier placement by the tiered decode law, and emit ready-to-run llama.cpp recipes.
5
5
  Author: Federico Sciuca
6
6
  License: MIT
@@ -118,6 +118,7 @@ Copyability is the whole mechanism: code answers repeat their input, prose inven
118
118
  ## When quantprobe won't help you
119
119
 
120
120
  - **Your model already fits comfortably in VRAM at 4 bits or more.** Community quants are near-lossless there, and — measured — quantizing further buys almost no speed once a model is resident: the same 7B at Q2_K vs Q4_K_M is 36% smaller and **4% slower**. Quantize to make a model *fit*; once it fits, stop.
121
+ - **You want a tight number for a model that fits entirely in VRAM.** This is the placement the law knows least well: across all seven models measured there, the real speed came in **faster than predicted every time — by 2% to 67%.** Read that row as a floor, not a ceiling. Seven points on one GPU don't identify a better formula, and we'd rather say so than move a constant on thin evidence. **This is the single most useful thing you can send us:** `quantprobe bench --contribute` on a GPU-resident model turns your machine into the datapoint that fixes it.
121
122
  - **You need task-level eval scores** (MMLU, HellaSwag). quantprobe measures perplexity and KL divergence only.
122
123
  - **Your architecture isn't in the fragility atlas** (four families so far). The probe still works on your model; the published priors just won't apply. *Open an issue with your result — those are the most valuable datapoints.*
123
124
  - **You want multi-token prediction modeled in the planner.** It isn't. Measured, the effect runs from **+17% (dense, GPU-resident) to −24% (MoE, experts in RAM)** — there's no single multiplier to apply. [Full 2×2 →](preregistrations/2026-07-24-law6-speculation-economics.md)
@@ -100,6 +100,7 @@ Copyability is the whole mechanism: code answers repeat their input, prose inven
100
100
  ## When quantprobe won't help you
101
101
 
102
102
  - **Your model already fits comfortably in VRAM at 4 bits or more.** Community quants are near-lossless there, and — measured — quantizing further buys almost no speed once a model is resident: the same 7B at Q2_K vs Q4_K_M is 36% smaller and **4% slower**. Quantize to make a model *fit*; once it fits, stop.
103
+ - **You want a tight number for a model that fits entirely in VRAM.** This is the placement the law knows least well: across all seven models measured there, the real speed came in **faster than predicted every time — by 2% to 67%.** Read that row as a floor, not a ceiling. Seven points on one GPU don't identify a better formula, and we'd rather say so than move a constant on thin evidence. **This is the single most useful thing you can send us:** `quantprobe bench --contribute` on a GPU-resident model turns your machine into the datapoint that fixes it.
103
104
  - **You need task-level eval scores** (MMLU, HellaSwag). quantprobe measures perplexity and KL divergence only.
104
105
  - **Your architecture isn't in the fragility atlas** (four families so far). The probe still works on your model; the published priors just won't apply. *Open an issue with your result — those are the most valuable datapoints.*
105
106
  - **You want multi-token prediction modeled in the planner.** It isn't. Measured, the effect runs from **+17% (dense, GPU-resident) to −24% (MoE, experts in RAM)** — there's no single multiplier to apply. [Full 2×2 →](preregistrations/2026-07-24-law6-speculation-economics.md)
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "quantprobe"
7
- version = "1.11.1"
7
+ version = "1.11.2"
8
8
  description = "Probe-then-quantize for LLMs: measure a model's fragility curve, plan bit/tier placement by the tiered decode law, and emit ready-to-run llama.cpp recipes."
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }
@@ -8,4 +8,4 @@ Three commands, all grounded in measured laws (see LAWS.md in the repo):
8
8
  Every constant in `plan` is fitted from measurements published in the repo, including two
9
9
  pre-registered hardware predictions confirmed within 8%.
10
10
  """
11
- __version__ = "1.11.1"
11
+ __version__ = "1.11.2"
@@ -135,12 +135,17 @@ def run(a):
135
135
  # actually does the ranking, so it has to say so too - a warning only one of two commands
136
136
  # gives is the inconsistency class that cost us the plan-vs-bench correction.
137
137
  roomier = next((r for r in ranked if r["bits"] >= 4.5 and "all in VRAM" in r["desc"]), None)
138
- if roomier and best["bits"] < 4.5 and "all in VRAM" in best["desc"]:
139
- print(f"\n note: everything here already fits in VRAM, and once a model fits, a lower quant")
140
- print(f" buys almost nothing. Measured on this class of card: the same 7B at Q2_K vs Q4_K_M")
141
- print(f" is 36% smaller and 4% SLOWER. The speeds above assume decode is bandwidth-bound,")
142
- print(f" which it stops being once the whole model is resident. The honest pick here is")
143
- print(f" {roomier['bits']:g}-bit (quality x{roomier['q']:.2f}) - same speed in practice, better answers.")
138
+ if "all in VRAM" in best["desc"]:
139
+ print(f"\n note: all-in-VRAM is the placement our law knows least well. Every model we have")
140
+ print(f" measured there ran FASTER than predicted - by 2% to 67% - so read the speeds above")
141
+ print(f" as a floor, not a ceiling.")
142
+ if roomier and best["bits"] < 4.5:
143
+ print(f" It also already fits, and a lower quant buys almost nothing once it does: the same")
144
+ print(f" 7B at Q2_K vs Q4_K_M is 36% smaller and 4% SLOWER. The honest pick here is")
145
+ print(f" {roomier['bits']:g}-bit (quality x{roomier['q']:.2f}) - same speed in practice, better answers.")
146
+ print(f" We only have one GPU, and one GPU cannot fix this. `quantprobe bench --contribute`")
147
+ print(f" turns your machine into the datapoint that would - you review it before sending, and")
148
+ print(f" results OUTSIDE our predicted band are the most valuable ones we can receive.")
144
149
  print(f"\n realize the pick:")
145
150
  print(f" quantprobe {REALIZE.get(best['bits'], 'quantize')}")
146
151
  print(f" quantprobe run --gguf <the file> ... # launches with: {best['flags']}")
@@ -121,27 +121,43 @@ def moe_split_flags(frac, n_layer):
121
121
 
122
122
 
123
123
  def fits_in_vram_advice(placement, bits):
124
- """Once a model fits in VRAM, quantizing it further buys almost no speed - measured.
125
-
126
- The law prices decode as bandwidth, so it predicts that halving the bits nearly halves the
127
- time. In the fits-entirely-in-VRAM regime that is simply not what happens. Same 7B, same
128
- card, all in VRAM, only the quantization changed (pre-registration #16, r=3):
129
-
130
- Q4_K_M 4.5 bits 4.68 GB 20.03 +/- 0.04 tok/s
131
- Q2_K 2.8 bits 3.01 GB 19.17 +/- 0.03 tok/s 36% smaller, 4% SLOWER
132
-
133
- Decode there is not bandwidth-bound, so bytes stop predicting speed. Until that regime is
134
- modelled properly the law over-rewards low bits here, and a user following the ranking alone
135
- would trade real quality for nothing. Say so, rather than silently ranking on a number known
136
- to be wrong in this direction.
124
+ """What we know, and admit we don't know, about the all-in-VRAM row.
125
+
126
+ This is the most common configuration for anyone with adequate VRAM, and it is where the law
127
+ is least trustworthy. Two separate facts, both measured, both worth telling the user:
128
+
129
+ 1. The prediction is CONSERVATIVE here. Across all seven models measured all-in-VRAM on the
130
+ reference box the real speed came in FASTER than predicted every single time, by 2% to
131
+ 67%. That is the opposite of the usual failure direction and it is not noise - it is a
132
+ one-directional bias (pre-registration #15, unresolved).
133
+
134
+ 2. Below 4.5 bits, quantizing further buys almost nothing. Same 7B, same card, only the
135
+ quantization changed (pre-registration #16, r=3):
136
+ Q4_K_M 4.5 bits 4.68 GB 20.03 +/- 0.04 tok/s
137
+ Q2_K 2.8 bits 3.01 GB 19.17 +/- 0.03 tok/s 36% smaller, 4% SLOWER
138
+ Decode here is not bandwidth-bound, so bytes stop predicting speed and the ranking
139
+ over-rewards low bits.
140
+
141
+ Why no fix instead of a disclaimer: seven points on ONE GPU do not identify a functional
142
+ form, and the last two times a constant moved on thin evidence it cost a public correction.
143
+ So the honest move is to say what we know, and ask for the datapoint that would settle it -
144
+ which is why this note ends in a request rather than an apology. The regime is pinned by a
145
+ ratchet in the test suite so it can improve but never silently worsen.
137
146
  """
138
- if placement != "all in VRAM" or bits >= 4.5:
147
+ if placement != "all in VRAM":
139
148
  return None
140
- return ("it already fits in VRAM, so going lower-bit buys you almost nothing. Measured on "
141
- "this class of card: the same 7B at Q2_K vs Q4_K_M is 36% smaller and 4% SLOWER "
142
- "(19.17 vs 20.03 tok/s). The speeds ranked above assume decode is bandwidth-bound, "
143
- "which it is not once the whole model sits in VRAM. Quantize to make a model FIT - "
144
- "once it fits, take the highest bits that still fit.")
149
+ note = ("this is the placement our law knows least well. Every model we have measured "
150
+ "all-in-VRAM ran FASTER than predicted - by 2% to 67% - so treat the number above as "
151
+ "a floor, not a ceiling.")
152
+ if bits < 4.5:
153
+ note += (" It also already fits, and going lower-bit buys almost nothing: the same 7B at "
154
+ "Q2_K vs Q4_K_M is 36% smaller and 4% SLOWER (19.17 vs 20.03 tok/s). Quantize "
155
+ "to make a model FIT - once it fits, take the highest bits that still fit.")
156
+ note += ("\n We only have one GPU, and one GPU cannot fix this. If you run this model, "
157
+ "`quantprobe bench --contribute` turns your machine into the datapoint that does - "
158
+ "it prints exactly what would be shared and you submit it yourself. Results that "
159
+ "land OUTSIDE our predicted band are the most valuable ones we can receive.")
160
+ return note
145
161
 
146
162
 
147
163
  def speculation_advice(moe, placement):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: quantprobe
3
- Version: 1.11.1
3
+ Version: 1.11.2
4
4
  Summary: Probe-then-quantize for LLMs: measure a model's fragility curve, plan bit/tier placement by the tiered decode law, and emit ready-to-run llama.cpp recipes.
5
5
  Author: Federico Sciuca
6
6
  License: MIT
@@ -118,6 +118,7 @@ Copyability is the whole mechanism: code answers repeat their input, prose inven
118
118
  ## When quantprobe won't help you
119
119
 
120
120
  - **Your model already fits comfortably in VRAM at 4 bits or more.** Community quants are near-lossless there, and — measured — quantizing further buys almost no speed once a model is resident: the same 7B at Q2_K vs Q4_K_M is 36% smaller and **4% slower**. Quantize to make a model *fit*; once it fits, stop.
121
+ - **You want a tight number for a model that fits entirely in VRAM.** This is the placement the law knows least well: across all seven models measured there, the real speed came in **faster than predicted every time — by 2% to 67%.** Read that row as a floor, not a ceiling. Seven points on one GPU don't identify a better formula, and we'd rather say so than move a constant on thin evidence. **This is the single most useful thing you can send us:** `quantprobe bench --contribute` on a GPU-resident model turns your machine into the datapoint that fixes it.
121
122
  - **You need task-level eval scores** (MMLU, HellaSwag). quantprobe measures perplexity and KL divergence only.
122
123
  - **Your architecture isn't in the fragility atlas** (four families so far). The probe still works on your model; the published priors just won't apply. *Open an issue with your result — those are the most valuable datapoints.*
123
124
  - **You want multi-token prediction modeled in the planner.** It isn't. Measured, the effect runs from **+17% (dense, GPU-resident) to −24% (MoE, experts in RAM)** — there's no single multiplier to apply. [Full 2×2 →](preregistrations/2026-07-24-law6-speculation-economics.md)
File without changes
File without changes