license: apache-2.0
base_model:
- KidIkaros/abliterated-minicpm5-2b-v2
- openbmb/MiniCPM5-2B
tags: - text-generation
- abliterated
- dpo
- sft
- tool-use
- gguf
- llama.cpp
- pytorch
Abliterated MiniCPM5-2B v3 (agentic)
Reduced-refusal, agentic-tuned derivative of
openbmb/MiniCPM5-2B:
re-ablation + DPO (v2) → agentic LoRA SFT → weight interpolation.
Unofficial derivative — not an OpenBMB release. Research artifact.
v3 supersedes KidIkaros/abliterated-minicpm5-2b-v2. It targets everyday agentic use: better tool calling and multi-turn tool-response synthesis at the same ~low refusal rate, with the math/knowledge cost of the SFT stage recovered via weight interpolation. Measured refusal: 2.7–6.7% across two seeds (vs ~37% official, ~8% v2) with 102.6% domain-macro retention vs official on a pinned local benchmark suite.
This checkpoint is v3_interp_a50 — a 50/50 weight interpolation between v2_merged (re-ablation + DPO) and v3_merged (v2 + agentic SFT). The interpolation preserved the SFT's agentic gains while recovering the math/knowledge capability the SFT had regressed.
Contents
| Path | What |
|---|---|
model.safetensors + configs/tokenizer |
Merged fp16 HF checkpoint — byte-identical to the evaluated candidate |
gguf/minicpm5-2b-v3-a50-f16.gguf |
F16 GGUF (llama.cpp) |
gguf/minicpm5-2b-v3-a50-q8_0.gguf |
Q8_0 GGUF |
gguf/minicpm5-2b-v3-a50-q4_k_m.gguf |
Q4_K_M GGUF |
Usage
transformers
from transformers import AutoModelForCausalLM, AutoTokenizer
model_id = "KidIkaros/abliterated-minicpm5-2b-v3"
tok = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(
model_id, torch_dtype="auto", device_map="auto",
)
msgs = [{"role": "user", "content": "Explain how a hash map works"}]
inputs = tok.apply_chat_template(
msgs, add_generation_prompt=True, return_tensors="pt",
).to(model.device)
out = model.generate(
inputs, max_new_tokens=256,
do_sample=True, temperature=1.0, top_p=0.95, min_p=0.0,
)
print(tok.decode(out[0][inputs.shape[1]:], skip_special_tokens=True))
Tool calling: pass tools=[...] to apply_chat_template — the MiniCPM5
template injects function signatures and the model emits<function name="..."><param name="...">value</param></function> XML.
Recommended decoding: temperature=1.0, top_p=0.95, min_p=0.0 (OpenBMB's
settings). Greedy decoding combined with thinking prompts can fall into
repetition loops — a quirk of the 2B base, present in the official model too.
llama.cpp
llama-cli -m minicpm5-2b-v3-a50-q8_0.gguf -ngl 99 -c 8192
Runtime smoke (RX 9060 XT, HIP): Q4_K_M ~103 tok/s.
GGUFs embed tokenizer.ggml.pre=minicpm5 and the production chat template
(including the tool-call block). Requires llama.cpp ≥ b9354 for theminicpm5 pre-tokenizer.
Refusal + agentic gates (300 prompts, temp 1.0 / top_p 0.95 / min_p 0.0)
| Candidate | fastgate refuse s0 | s1 | toolcall s0 | s1 | agentic s0 | s1 |
|---|---|---|---|---|---|---|
| official MiniCPM5-2B | ~37% | — | 82.4% | — | ~77% | — |
| v2 | ~8% | ~8% | 78.8% | 83.5% | 71.4% | 76.8% |
| v3 (this repo) | 2.7% | 6.7% | 82.4% | 87.1% | 73.2% | 85.7% |
toolcall = 85-row sealed suite (single-call, arg-extraction, no-call,
multi-intent; deterministic XML grader). agentic = 56-record two-turn
chained suite (emit call → synthesize tool response). Residual refusals are
mostly stochastic boundary flips at temp 1.0.
Benchmarks — release_core suite (lm-eval 0.4.13)
Identical pinned local harness for all candidates: same tokenizer/chat
template, prompts, decoding, model-loading settings. No-thinking mode.
Seeds 0 and 1 for MMLU-Pro / MATH-500 / IFEval; seed 0 for LongBench-E.
Scores are not comparable to OpenBMB's published leaderboard values.
| Task | n | official | v2 | v3_sft (rejected) | v3 (this repo) |
|---|---|---|---|---|---|
| MMLU-Pro | 350×2 | 42.57 | 38.43 | 36.43 | 40.43 |
| MATH-500 | 500×2 | 50.30 | 47.30 | 40.10 | 46.90 |
| IFEval | 541×2 | 84.94 | 85.58 | 85.49 | 84.84 |
| LongBench-E single-doc QA | 6 | 65.56 | 82.22 | 74.15 | 74.15 |
| LongBench-E multi-doc QA | 6 | 77.78 | 66.67 | 50.00 | 66.67 |
| LongBench-E summarization | 6 | 29.23 | 28.86 | 28.09 | 27.41 |
| LongBench-E synthetic | 6 | 0.00 | 66.67 | 66.67 | 50.00 |
| domain macro | 55.24 | 58.10 | 54.19 | 56.68 |
Domain-macro retention vs official: 102.6% (predeclared target ≥95% —
PASS).
Honest notes:
- Residual regressions remain: MMLU-Pro −2.1pp and MATH-500 −3.4pp vs
official. The agentic SFT stage alone cost −7.2pp MATH; interpolation
recovered it to within noise of v2. longbench_synthetic_eis decode-sensitive: official emits EOS within
0–2 tokens under greedy no-thinking decoding on ~3.6k-word prompts
(early-EOS pathology, not capability). a50's 50.00 sits midway.- LongBench-E groups are n=6 — smoke-tier signal only.
Lineage
KidIkaros/abliterated-minicpm5-2b @ 5c315b8 (v0)
└─ re-ablation + DPO → v2_merged
└─ agentic LoRA SFT (r16/α32, lr 1e-4, 1 ep,
UltraData-SFT-Agent + refusal replay) → v3_merged
└─ weight interpolation α=0.5(v2_merged, v3_merged) → v3_interp_a50 ★
Integrity
sha256 — verify after download or any copy:
| File | sha256 |
|---|---|
model.safetensors |
efd2e0f94deeba3583ced0569e5628728798402a4558951a2a8426c9181a8020 |
gguf/minicpm5-2b-v3-a50-f16.gguf |
33ec9b48a41014f37c61ec5ad1a293a3e8c7903446c9647f9c333770c0848407 |
gguf/minicpm5-2b-v3-a50-q8_0.gguf |
a54b80e0de779a5ddc218da827ff4e12fc84458e94e169a6e798b86fc972070f |
gguf/minicpm5-2b-v3-a50-q4_k_m.gguf |
4c2dd0ae9f6cfbc683b0b383cc49b1c65191c8027db121151a4fc4c67909356a |
Known limitations
- Residual refusal is temperature-boundary stochastic (2.7–6.7%); a small
number of defensible safety refusals remain. - MMLU-Pro / MATH-500 sit ~2–3.4pp below official (see above).
- Occasionally narrates a hallucinated tool result instead of emitting
<function>XML (reduced vs v2, not eliminated — base-model quirk). - Text-only; no multimodal.
- This is a research artifact for studying refusal behavior — it has
reduced safety-refusal behavior and is not a safety-aligned product.