A multi-token-prediction (MTP) head for Ternary-Bonsai-2-27B, re-trained on Japanese text written by Bonsai itself so that its drafts are accepted more often in Japanese chat. Unofficial; not affiliated with Prism ML.
| original head | this head | |
|---|---|---|
| draft acceptance (Japanese prompts, vLLM, 1 draft token) | 65.9% | 70.0% |
| decode speed (2x RTX 5070, TP=2) | 90.8 tok/s | 93.6 tok/s |
The MTP head only proposes tokens; every token is verified by the main model, so the output distribution does not change.
model_mtp.safetensors — the 15 mtp.* tensors (bf16, 0.85 GB), same names/shapes as the MTP head in fraserprice/Ternary-Bonsai-2-27B-vllm.
Swap the tensors into the 3rd shard of the vLLM-format model, then serve with --speculative-config '{"method":"mtp","num_speculative_tokens":1}':
python model/swap_mtp.py <model_dir> model_mtp.safetensors
swap_mtp.py and the full setup are in Nakanokensetsu/bonsai-27b-wsl-tp2.
Bonsai 2 27B の先読み(MTP)ヘッドを、Bonsai 自身が書いた日本語で学習し直したものです。先読みの当たる率が 65.9% → 70.0% になりました。先読みは本体が必ず確かめるので、出力の分布は変わりません。
ProCreations/Ternary-Bonsai-2-27B-MTP