Downloads · 30 days
233
26% of all-time downloads
Mati83moni/PLLuM-12B-chat-2512-EXL3
PLLuM-12B-chat-2512-EXL3 is a text generation model from Mati83moni. Use it when you need the model to write or continue text. It is set up for exllamav3. The card lists the license as apache-2.0.
<p align="center" <img src="PLLuMlogoRGBcolor.png" width="400" </p
Downloads · 30 days
233
26% of all-time downloads
All-time downloads
904
Public
Parameters
4B
8 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors8 GB · 100%
How the weights are stored.
I163.3B · 83%
From the Hugging Face model README
EXL3 quantization of CYFRAGOVPL/PLLuM-12B-chat-2512 — a 12B Polish chat LLM by the PLLuM / HIVE AI consortium, optimized for 12 GB VRAM.
Quantized by @Mati83moni using ExLlamaV3 (v0.0.43) on AWS EC2.
Created on request from the HuggingFace community (Discussion #1).
You may notice the sidebar shows "Model size: 4B params" — this is not accurate and is a known limitation of HuggingFace's automatic parameter counter for EXL3 models.
This model has the full ~12B parameters of the original PLLuM-12B-chat-2512.
Why the discrepancy? EXL3 uses trellis-encoded weight packing, where each weight
tensor is compressed into a .trellis sub-tensor with a different shape than the
original weight matrix (e.g. a [14336, 5120] weight becomes a [320, 896, 64]
int16 trellis tensor). HuggingFace's parameter counter sums raw tensor element counts
from the safetensors header, which — for trellis-packed formats — does not correspond
to the actual number of model parameters. This affects all EXL3 models on HuggingFace,
not just this one.
Ground truth parameter count: 12B (verify via config.json: hidden_size=5120,
num_hidden_layers=40, intermediate_size=14336, vocab_size=131072 — matching the
original PLLuM-12B-chat-2512 architecture exactly).
| Parameter | Value |
|---|---|
| Format | EXL3 (ExLlamaV3) |
| BPW (decoder) | 4.5 (weighted mean of per-tensor bitrates in quantization_config.json; 4.505 incl. scale vectors per model.get_storage_info()) |
| BPW (head) | 6.0 |
| Model Size | 7.99 GB (7.44 GiB) — model.safetensors |
| SQNR (average) | ~33 dB as reported by the converter during quantization (not re-measured); measured weight-space SQNR: see Quality Assessment |
| Quantization Tool | exllamav3 v0.0.43 |
| Quantization GPU | NVIDIA L4 24 GB (AWS g6.2xlarge) |
| Quantization Time | ~75 min |
| Calibration | Default (250 rows × 2048 columns) |
quantization_config.jsonstores"bits": 4(an integer) — this is how ExLlamaV3 v0.0.43 records the base bitrate; the actual per-tensor allocation below averages to 4.5 bpw over the decoder linear layers.
Per-tensor bitrates read from quantization_config.json (tensor_storage[*].bits_per_weight):
| Layer Group | BPW | Note |
|---|---|---|
| Embedding / Norm | 16 bpw | Unquantized (BF16) |
| Attention q/k/v/o (layer 0) | 6 bpw | Higher precision for the first layer |
| Attention q/k/v/o (layers 1–39) | 5 bpw | Standard precision |
| MLP gate/up/down (layers 0–14) | 5 bpw | Higher precision for early layers |
| MLP gate/up/down (layers 15–39) | 4 bpw | Aggressive compression |
| lm_head | 6 bpw | Higher precision for output |
Measured on NVIDIA Tesla T4 (16 GB), ExLlamaV3 0.0.43 (+ sm_75 patch, see Benchmarks), batch size 1,
FP16 KV cache, model and cache on one GPU. "nvidia-smi" includes the CUDA context; "PyTorch" is torch.cuda.max_memory_allocated.
| Context Length | VRAM after load (weights + KV cache) | Peak VRAM (nvidia-smi) | Fits 12 GB? |
|---|---|---|---|
| 2,048 tokens | 6.75 GiB | 7.50 GiB | ✅ Yes |
| 4,096 tokens | 7.17 GiB | 7.93 GiB | ✅ Yes |
| 8,192 tokens | 7.75 GiB | 8.51 GiB | ✅ Yes |
| 16,384 tokens | 9.00 GiB | 9.76 GiB | ✅ Yes |
| 32,768 tokens | 11.50 GiB | 12.26 GiB | ❌ No (needs 16 GB) |
The "Fits 12 GB?" column is derived from the T4 measurement (peak < 95 % of 12 GiB = ✅, < 12 GiB = ⚠️). Peak VRAM on other GPUs/drivers can differ slightly (CUDA context size, attention backend). The FP16 KV cache costs 160 KiB per token (40 layers × 8 KV heads × 128 dims × 2 × FP16).
| Parameter | Value |
|---|---|
| Architecture | MistralForCausalLM |
| Parameters | ~12B |
| Layers | 40 |
| Embedding Dimension | 5,120 |
| Attention Heads | 32 |
| KV Heads (GQA) | 8 |
| Context Length | 131,072 tokens (max_position_embeddings in config.json); measured here up to 32,768 |
| Vocab Size | 131,072 tokens (config.json vocab_size; tokenizer.json has 131,072 ids, incl. 1,000 control tokens 0–999) |
| Original Precision | BF16 |
PLLuM (Polish Large Language Model) is a family of LLMs specialized for the Polish language, developed by the PLLuM consortium and continued under HIVE AI — an alliance of research institutions delivering digital public services for Polish public administration.
# config.yml
model_dir: /path/to/PLLuM-12B-chat-2512-EXL3-4.5bpw
max_seq_len: 4096
python start.py --model-dir PLLuM-12B-chat-2512-EXL3-4.5bpw
from exllamav3 import ExLlamaV3Config, ExLlamaV3, ExLlamaV3Tokenizer
from exllamav3.generator import ExLlamaV3DynamicGenerator
model_dir = "PLLuM-12B-chat-2512-EXL3-4.5bpw"
config = ExLlamaV3Config(model_dir)
model = ExLlamaV3(config)
model.load()
tokenizer = ExLlamaV3Tokenizer(config)
generator = ExLlamaV3DynamicGenerator(model=model, tokenizer=tokenizer)
prompt = "[INST]Wyjaśnij czym jest uczenie maszynowe w 3 zdaniach.[/INST]"
output = generator.generate(prompt=prompt, max_new_tokens=512)
print(output)
This model uses the Mistral Instruct template exactly as defined in chat_template.jinja (no spaces around the tags):
<s>[INST]<system prompt (optional)>\n\n<user message>[/INST]<assistant response></s>[INST]<next user message>[/INST]
The chat_template.jinja file is included in this repo and will be automatically detected by TabbyAPI and ExLlamaV3.
| Parameter | Value |
|---|---|
| Temperature | 0.6 |
| Top-p | 0.9 |
| Repeat penalty | 1.1 |
Only one GPU was tested. Speeds for other GPUs are not measured and are intentionally not listed.
| Setup | VRAM | Context | Prefill (tok/s) | Decode (tok/s) |
|---|---|---|---|---|
| Tesla T4 16 GB (sm_75, patched ExLlamaV3) | 7.5 GiB peak | 2,048 | 363 | 7.8 (at token 1920) |
| Tesla T4 16 GB (sm_75, patched ExLlamaV3) | 8.5 GiB peak | 8,192 | 205 | 3.2 (at token 8064) |
| Tesla T4 16 GB (sm_75, patched ExLlamaV3) | 12.3 GiB peak | 32,768 | 74 | 0.9 (at token 32640) |
T4 numbers are a lower bound: on sm_75 the patched kernels replace
cp.asyncwith synchronous copies and split each tensor-core MMA in two, and FlashAttention-2 is unavailable (Triton paged attention is used for decoding). They are not representative of Ampere/Ada/Hopper GPUs.
💡 Why EXL3? EXL3 is the native format of ExLlamaV3, an inference library for local GPUs. This repository makes no speed comparison with other quantization formats; the only speed numbers here are the T4 measurements above.
All numbers in this section were measured on 2026-10-04 on NVIDIA Tesla T4 16 GB (15360 MiB usable, sm_75), driver 580.178.04, Kaggle, with
ExLlamaV3 0.0.43 (commit c5d9c65) + sm_75 compatibility patch, PyTorch 2.11.0+cu128 (CUDA 12.8), Python 3.13.15,
transformers 5.16.1, datasets 4.8.5, Triton 3.6.0, lm-evaluation-harness 0.4.13.
Model revisions: this repo 278a520af92f, original CYFRAGOVPL/PLLuM-12B-chat-2512 19a26cf61648.
Seed 0 everywhere a seed applies (all decoding is greedy). All measured values are in
benchmarks/results.json; the scripts are in benchmarks/ (see Reproduce).
Why a patch? ExLlamaV3 v0.0.43 is built for sm_80+ only; the free Kaggle GPUs are Tesla T4 (sm_75). A minimal patch
(benchmarks/patch_sm75.py, 7 items, diff ~100 lines) makes it run on Turing. On sm_80+ the patched sources compile to the upstream device code.
The patched kernels were validated: for all 281 linear layers the fused EXL3 GEMM kernel and the
reconstruct-then-cuBLAS path agree to a worst-case relative error of 5.5e-04 (FP16 rounding level) for 1, 4 and 16 rows.
| Text | Rows × ctx (scored tokens per model) | PPL original (BF16 weights) | PPL EXL3 4.5 bpw | Δ PPL |
|---|---|---|---|---|
| English — WikiText-2 (raw, test) | 100 × 2048 (204,700 scored) | 7.1134 | 7.1761 | +0.88 % |
| Polish — Wikipedia (pl, 20231101) | 100 × 2048 (204,700 scored) | 3.9972 | 4.0433 | +1.15 % |
eval/model_diff.py (ExLlamaV3 v0.0.43). Model A = this EXL3 repo, model B = the original
checkpoint. Both models process the same token ids module by module (layer-by-layer, so the 24.5 GB original fits on a 16 GB T4);
100 non-overlapping rows of 2048 tokens (stride 2048), no BOS, PPL over all 2047 next-token predictions per row.model_diff.py, not from an external source.eval/ppl.py could not be used as an independent cross-check: in v0.0.43 it crashes in model_init.init ('Namespace' object has no attribute 'mtp').Polish evaluation text. wikimedia/wikipedia, config 20231101.pl, split train, dataset revision
b04c8d1ceb2f: the first 60 articles in dataset order with ≥ 3,000 characters,
joined with blank lines (780,272 characters, 248,098 tokens; SHA-256 0c54af15dd07d429…); the first
100 × 2048 tokens are used. First articles: AWK, ASCII, Atom, Aksjomat, Arytmetyka.
Overlap with ExLlamaV3's default calibration corpus (13-word shingles): Polish text 0 / 105066
shingles, WikiText-2 test 0 / 206132. Wikipedia is very likely part of PLLuM's
own training data, which lowers the absolute PPL of both models equally; only the EXL3-vs-original difference is meaningful.
| Text | KL(BF16 ‖ EXL3) [nats/token] | KL(EXL3 ‖ BF16) | Top-1 agreement | Top-5 agreement (exact top-5 set & order) | Top-1 acc. BF16 | Top-1 acc. EXL3 |
|---|---|---|---|---|---|---|
| English — WikiText-2 | 0.01718 | 0.01746 | 0.9449 | 0.3942 | 0.5642 | 0.5624 |
| Polish — Wikipedia | 0.01927 | 0.02009 | 0.9491 | 0.3577 | 0.6802 | 0.6785 |
Same runs as the perplexity table (model_diff.py, 100 × 2048 tokens per language). KL is computed over the full
131,072-token vocabulary and averaged per position. "Top-K agreement" = fraction of positions where the K most likely tokens of both
models are identical (in order); "Top-1 acc." = fraction of positions where the model's argmax equals the actual next token.
| Task (lm-eval name) | What it measures | Dataset (split) | n | Metric | EXL3 4.5 bpw | Original BF16 | Δ (pp) |
|---|---|---|---|---|---|---|---|
belebele_pol_Latn | reading comprehension, 4-way MC | facebook/belebele (pol_Latn, test) | 900 | acc | 81.89 ± 1.28 | 81.44 ± 1.30 | +0.44 |
| acc_norm | 81.89 ± 1.28 | 81.44 ± 1.30 | +0.44 | ||||
polemo2_in | KLEJ PolEmo2.0-IN sentiment, generative | allegro/klej-polemo2-in (test) | 722 | accuracy | 74.65 ± 1.62 | 74.52 ± 1.62 | +0.14 |
| F1 (micro) | 74.65 ± 1.62 | 74.52 ± 1.62 | +0.14 | ||||
polemo2_out | KLEJ PolEmo2.0-OUT sentiment, generative | allegro/klej-polemo2-out (test) | 494 | accuracy | 77.13 ± 1.89 | 77.33 ± 1.89 | -0.20 |
| F1 (micro) | 77.13 ± 1.89 | 77.33 ± 1.89 | -0.20 | ||||
arc_challenge_mt_pl | ARC-Challenge, machine-translated to Polish | LumiOpen/arc_challenge_mt (pl, test) | 1172 | acc | 45.90 ± 1.46 | 47.18 ± 1.46 | -1.28 |
| acc_norm | 46.59 ± 1.46 | 47.78 ± 1.46 | -1.19 | ||||
global_piqa_nonparallel_cloze_pol_latn | physical commonsense (PIQA-style), cloze | mrlbenchmarks/global-piqa-nonparallel (pol_latn, test) | 100 | acc | 74.00 ± 4.41 | 73.00 ± 4.46 | +1.00 |
| acc_norm | 75.00 ± 4.35 | 73.00 ± 4.46 | +2.00 | ||||
include_base_44_polish | regional exam questions, 4-way MC (3 subsets, size-weighted) | CohereForAI/include-base-44 (Polish, test) | 548 | acc | 54.74 ± 2.08 | 55.66 ± 2.08 | -0.91 |
simple_evaluate, num_fewshot=0, no chat template, BOS prepended,
max length 2048, limit=None = full test sets), with an ExLlamaV3 model wrapper (benchmarks/lm_exl3.py): log-likelihoods
from one full forward pass per sequence; generative tasks (PolEmo2) use greedy decoding with the task's stop strings.
Values are percentages ± bootstrap/standard error as reported by lm-eval.-2512 checkpoints on these tasks.| Context (KV cache size) | VRAM after load incl. KV cache (nvidia-smi) | Peak VRAM (nvidia-smi) | Peak allocated (PyTorch) | Prefill tok/s (full context, median of 3) | Decode tok/s at end of context (median of 3) |
|---|---|---|---|---|---|
| 2,048 | 6.75 GiB | 7.50 GiB | 7.19 GiB | 363.2 | 7.85 |
| 4,096 | 7.17 GiB | 7.93 GiB | 7.50 GiB | 281.6 | 5.27 |
| 8,192 | 7.75 GiB | 8.51 GiB | 8.10 GiB | 204.7 | 3.18 |
| 16,384 | 9.00 GiB | 9.76 GiB | 9.35 GiB | 128.6 | 1.78 |
| 32,768 | 11.50 GiB | 12.26 GiB | 11.85 GiB | 73.9 | 0.93 |
nvidia-smi sampled every 50 ms (includes CUDA context) and PyTorch allocator peak.eval/perf.py could not be used: in v0.0.43 it crashes in model_init.init ('Namespace' object has no attribute 'mtp').10 fixed prompts (diacritics, grammar, inflection, summarization, instructions), greedy decoding, max_new_tokens=512,
chat template, EXL3 model. Full prompts and answers: benchmarks/qualitative_pl.json.
Observations (manual reading, not a metric): fluent Polish with correct diacritics in all answers; correct inflection table for
przyjaciel; correct numeral agreement; good one/two-sentence summaries. Errors seen: prompt 1 (restore diacritics) changed
words instead of only adding diacritics; prompt 2 produced two sentences instead of three; prompt 4 gave a wrong justification;
prompt 9 contains factual inaccuracies about the ID-card procedure; prompt 10 invents a detail (a bad smell) not in the request.
Same prompts on the original BF16 model (2× T4, same settings): answers 1 and 4 are token-for-token identical to EXL3 (the
same errors), the other 8 differ in wording only; BF16 shows the same kinds of errors (prompt 2: one sentence; prompt 9: similar
procedural inaccuracies; prompt 10: invents a floor number). The observed errors are therefore behaviour of the original model,
not quantization artefacts. Both answer sets: benchmarks/qualitative_pl.json (EXL3) and benchmarks/qualitative_pl_bf16.json (BF16).
| Metric | Value | Interpretation |
|---|---|---|
| Δ PPL vs original, Polish Wikipedia (ctx 2048) | +1.15 % | model_diff.py, 100 × 2048 tokens |
| Δ PPL vs original, WikiText-2 (ctx 2048) | +0.88 % | model_diff.py, 100 × 2048 tokens |
| KL(BF16 ‖ EXL3), PL / EN | 0.0193 / 0.0172 nats/token | full-vocabulary KL, mean over positions |
| Top-1 agreement with original, PL / EN | 0.9491 / 0.9449 | same argmax token |
| Weight-space SQNR (decoder linears, mean / min) | 26.7 / 21.9 dB | 10·log10(‖W‖² / ‖W − Ŵ‖²) per tensor vs BF16 |
| Weight-space SQNR by bitrate (4 / 5 / 6 bpw) | 22.6 / 28.1 / 33.4 dB | mean per tensor group |
| Polish tasks, Δ EXL3 − original (primary metric of each of 6 tasks) | -1.28 … +1.00 pp | each absolute Δ is smaller than one standard error |
| Belebele (pol_Latn), 0-shot acc, EXL3 / BF16 | 0.8189 / 0.8144 | same harness, same settings |
| Compression ratio | 3.1× | From 24.5 GB (BF16 safetensors) to 7.99 GB |
Measured against the original weights on identical token sequences (ctx 2048): perplexity changes by +1.15 % on Polish Wikipedia and +0.88 % on English WikiText-2; mean KL divergence KL(BF16‖EXL3) is 0.0193 (PL) / 0.0172 (EN) nats per token, and the EXL3 model picks the same top-1 token as the original in 94.9 % (PL) / 94.5 % (EN) of positions. On six Polish downstream tasks the EXL3 model scores within one standard error of the original (differences between −1.3 and +1.0 pp on the primary metrics). This is a measurement on two text sets at one context length, not a guarantee for every use case.
All scripts used for the numbers on this card are in benchmarks/; benchmarks/README.md
lists every file, the library versions and the GPU requirements. All measured values are in
benchmarks/results.json. The evaluation texts are rebuilt from public datasets by
make_eval_texts.py, which checks their SHA-256. On an Ampere or newer GPU skip the patch/build in step 0 and install the official wheel.
# 0) ExLlamaV3 v0.0.43 for Turing (T4): apply the patch, build for sm_75 (~10 min on 4 vCPU)
git clone --depth 1 --branch v0.0.43 https://github.com/turboderp-org/exllamav3
python benchmarks/patch_sm75.py exllamav3 # idempotent
(cd exllamav3 && TORCH_CUDA_ARCH_LIST=7.5 MAX_JOBS=4 pip wheel --no-deps --no-build-isolation -w ../wheels .)
pip install --no-deps wheels/exllamav3-0.0.43-*.whl
pip install rich pyyaml marisa_trie pydantic ninja "lm-eval==0.4.13" evaluate scikit-learn
# 1) Models
huggingface-cli download Mati83moni/PLLuM-12B-chat-2512-EXL3 --local-dir exl3
huggingface-cli download CYFRAGOVPL/PLLuM-12B-chat-2512 --local-dir bf16 --include "*.safetensors" "*.json" "tokenizer*" "*.jinja"
# 2) Evaluation texts (CPU): Polish Wikipedia (20231101.pl, revision b04c8d1ceb2f, first 60 articles >= 3,000 chars)
# and WikiText-2 test; SHA-256 is verified. Then the overlap check against the calibration corpus.
python benchmarks/make_eval_texts.py --out-dir eval_texts --meta
python benchmarks/calibration_overlap.py --exllamav3-repo exllamav3 --texts eval_texts/pl_wiki_eval.txt eval_texts/en_wikitext2_test.txt
# 3) Kernel check (fused EXL3 GEMM vs reconstruct path, all linear layers)
python benchmarks/validate_kernels.py --model exl3 --out validate.json
# 4) PPL / KLD / top-K vs original, ctx 2048, 100 rows (upstream eval/model_diff.py, text source swapped), weight SQNR
python benchmarks/model_diff_text.py --exllamav3-repo exllamav3 --model-a exl3 --model-b bf16 --rows 100 --text eval_texts/pl_wiki_eval.txt
python benchmarks/model_diff_text.py --exllamav3-repo exllamav3 --model-a exl3 --model-b bf16 --rows 100 --text eval_texts/en_wikitext2_test.txt
python benchmarks/weight_sqnr.py --exl3 exl3 --bf16 bf16 --out weight_sqnr.json
# 5) Polish tasks, 0-shot: EXL3 on one GPU, original BF16 split over 2x T4
python benchmarks/run_lm_eval.py --model exl3 --out lm_eval_exl3
python benchmarks/run_lm_eval.py --model bf16 --split --out lm_eval_bf16
# 6) VRAM / speed, one process per context length
for c in 2048 4096 8192 16384 32768; do python benchmarks/perf_ctx.py --model exl3 --ctx $c --out perf; done
# 7) Qualitative prompts (benchmarks/prompts_pl.json)
python benchmarks/qualitative.py --model exl3 --out qualitative_pl.json
python benchmarks/qualitative.py --model bf16 --split --out qualitative_pl_bf16.json
convert.py with target BPW 4.5# Quantization command
python convert.py \
-i /path/to/PLLuM-12B-chat-2512 \
-w /path/to/work_dir \
-o /path/to/PLLuM-12B-chat-2512-EXL3-4.5bpw \
-b 4.5
| Component | Detail |
|---|---|
| Platform | AWS EC2 g6.2xlarge |
| GPU | NVIDIA L4 24 GB |
| ExLlamaV3 | v0.0.43 |
| PyTorch | 2.7.0+cu128 |
| CUDA | 12.8 |
| Source Precision | BF16 → EXL3 |
This quantization is distributed under the Apache 2.0 License, inherited from the original model.