/ Модель

Характеристики

Контекст
32 768 токенов
Параметры
7,1 млрд
Размер весов
15,2 ГБ
Лицензия
Apache 2.0
Архитектура
a2d-qwen2 · dense
Базовая модель
Qwen2.5-7B-Instruct
Библиотека
transformers
Опубликована
20 апр 2026

MARS-Qwen2.5-7B-blk16

Генерация текстаТекст → текст3 профессии
80скачиваний за 30 дней0лайковвеса обновлены23 окт 2026

Описание модели

Составлено на русском по карточке модели и метаданным Hugging Face

Дообученная на базе Qwen2.5-7B-Instruct модель для ускоренной генерации текста блоками по 16 токенов и экспериментов с декодированием MARS и ProVe.

MARS-Qwen2.5-7B-blk16 — дообученная модель Xalphinions на базе Qwen2.5-7B-Instruct с методом MARS для многотокенной генерации. В обычном авторегрессионном режиме она работает как стандартная языковая модель; при декодировании MARS за один проход предлагает блок из 16 токенов. Модель также используется как proposer в алгоритмах ProVe и ProVe-lossless, ускоряющих генерацию за счёт проверки предложенного блока.

Архитектура Qwen2 без дополнительных параметров, голов или модулей; метаданные указывают 7,1 млрд параметров, а README — 7,6 млрд. Контекст — 32 768 токенов. Модель принимает текст и выдаёт текст, поддерживает диалоговый режим и рассчитана прежде всего на английские инструкции. В описанном тесте ProVe-lossless показал ускорение 1,85 раза относительно жадного авторегрессионного декодирования на GSM8K, сохраняя его логику принятия токенов; возможны расхождения выходов из-за различий вычислительных ядер и выбора токенов при близких оценках.

Выпущенный код обслуживания поддерживает только жадное декодирование, а размер блока фиксирован и равен 16. Дообучение выполнено на английских инструкционных данных; поведение на других языках не оценивалось. Дополнительное выравнивание безопасности и red teaming не проводились. Лицензия — Apache-2.0.

Сценарии применения

  • ускорение жадной генерации ответов на инструкции
  • ускоренное формирование диалоговых ответов
  • исследование многотокенной генерации текста
  • проверка proposer-verifier декодирования
  • сравнение блочного декодирования с обычной авторегрессионной генерацией

Ограничения

В выпущенном коде ProVe доступно только жадное декодирование, а размер блока фиксирован на 16 токенах. Дообучение и оценка проводились на английском; дополнительные проверки безопасности не выполнялись.

Публичные бенчмарки

Результаты из открытых лидербордов в сравнении с лидерами каталога

Публичных оценок пока нет

В подключённых источниках результатов этой модели не нашлось. Отсутствие оценки не значит, что модель хуже: её могли просто не проверять.

Источники: Hugging Face Leaderboards, Hugging Face Eval Results, Open LLM v2, MTEB, timm, Open ASR, EvalPlus

Для каких профессий подходит3

Разделы каталога профессий, в задачах которых используется эта модель

Все профессии

Карточка модели

README от автора на Hugging Face, как он его опубликовал

Открыть на Hugging Face

MARS-Qwen2.5-7B-blk16

Qwen2.5-7B-Instruct fine-tuned with MARS (MARS: Enabling Autoregressive Models Multi-Token Generation; Jin, Wang, Luo, Sun, 2026), block size 16. One forward pass predicts a block of 16 tokens from 16 placeholder tokens; decoded ordinarily (no placeholders) the same weights are a normal autoregressive (AR) model. No extra parameters, heads or modules.

It is also the 7B proposer used in the quick start of ProVe: Proposer-Verifier Decoding (Jin, Xu, Li, Zhong, She, Sun, 2026). There a verifier reads the proposed block in one more forward pass and commits the longest prefix it accepts:

Model details

ArchitectureQwen2 (unchanged: no extra parameters, heads or modules)
Parameters7.6B
Base modelQwen/Qwen2.5-7B-Instruct (Apache-2.0)
Block size16 (block_size: 16 must be used at serving time)
Placeholder token`<
Precisionbf16 safetensors, 4 shards
Context lengthas the base model (32k)
Checkpoint formatconfig.json carries model_type: a2d-qwen2 / architectures: [A2DQwen2LMHeadModel] as written by the MARS trainer; rewrite it to qwen2 / Qwen2ForCausalLM for serving (ProVe's serve.sh does this for you). The weights are plain Qwen2 weights.
LicenseApache-2.0

Training

Two stages on the same public instruction data, both 5 epochs on allenai/Dolci-Instruct-SFT (about 2M rows), learning rate 5e-6, warmup ratio 0.03, effective batch 384, sequence length 512:

Stage 1: AR SFTStage 2: MARS block training
InitQwen2.5-7B-Instructstage-1 checkpoint (MARS-Qwen2.5-7B-AR-SFT)
Objectivenext-token cross-entropynext-token loss on the clean stream + block-prediction loss on the placeholder stream (block size 16)

Stage 1 exists so that the effect of the block objective can be measured against a matched AR control. Recipe, scripts and the MARS paper's own evaluation: https://github.com/Xalp/MARS.

How to use

ProVe / ProVe-lossless serving

git clone https://github.com/Xalp/ProVe.git && cd ProVe/inference && bash setup_env.sh
hf download Xalphinions/MARS-Qwen2.5-7B-blk16 --local-dir models/MARS-Qwen2.5-7B-blk16

# ProVe-lossless: the proposer verifies its own block; output == greedy AR; one GPU
bash serve.sh --proposer models/MARS-Qwen2.5-7B-blk16 --port 30000

# ProVe with a 3B verifier (theta 0.10 / 0.05 / 0.01: lower = faster, lossier)
hf download Qwen/Qwen2.5-3B-Instruct --local-dir models/Qwen2.5-3B-Instruct
bash serve.sh --proposer models/MARS-Qwen2.5-7B-blk16 \
              --verifier models/Qwen2.5-3B-Instruct --theta 0.05 --port 30001

serve.sh rewrites the config (weights are linked, not copied), writes the algorithm yaml and starts an SGLang server with the usual /generate and OpenAI-compatible /v1/chat/completions endpoints. --algorithm mars-tau serves the original MARS confidence-gated decoding (threshold τ, no verifier model) on the same stack; the MARS repository has the reference implementation.

Plain AR use with transformers

The checkpoint also works as an ordinary causal LM once the config names the Qwen2 architecture:

from transformers import AutoConfig, AutoModelForCausalLM, AutoTokenizer
path = "models/MARS-Qwen2.5-7B-blk16"
cfg = AutoConfig.from_pretrained("Qwen/Qwen2.5-7B-Instruct")      # same architecture
model = AutoModelForCausalLM.from_pretrained(path, config=cfg, torch_dtype="bfloat16", device_map="auto")
tok = AutoTokenizer.from_pretrained(path)

(or run python inference/tools/prepare_checkpoint.py <dir> once and load the <dir>-qwen2 copy).

Measured with the ProVe stack

GSM8K (gsm8k_cot), greedy, one request at a time, up to 1024 new tokens, one GPU, relative to greedy AR decoding of this checkpoint on the same stack. This 7B experiment is not in the ProVe paper, whose tables use the 32B proposer Xalphinions/ProVe-Qwen2.5-32B-blk16.

configurationtok/sspeed-upaccepted tokens per cycleGSM8K accuracy
greedy AR2341×–74.4
ProVe-lossless4331.85×6.1375.1

The two accuracies differ although the method is lossless by construction: the block path and the AR path run different kernels, and at a near-tie token their bf16 logits can pick different winners (in a 40-prompt, 512-token check 28 outputs were byte-identical). The ProVe paper therefore compares task accuracy, not byte identity.

Intended use and limitations

  • Research on multi-token generation and inference acceleration, and as a drop-in for Qwen2.5-7B-Instruct-class AR decoding where single-request throughput matters.
  • Greedy decoding only in the released ProVe serving code; sampling is not implemented.
  • The block size is fixed at training time (16); serving with another block size is not supported.
  • Fine-tuned on English instruction data; behaviour on other languages follows the base model but was not evaluated.
  • Safety behaviour is inherited from Qwen2.5-7B-Instruct and the public instruction data; no additional alignment or red-teaming was done. Apply the same safeguards you would apply to the base model.

Citation

@misc{jin2026mars,
  title         = {MARS: Enabling Autoregressive Models Multi-Token Generation},
  author        = {Ziqi Jin and Lei Wang and Ziwei Luo and Aixin Sun},
  year          = {2026},
  eprint        = {2604.07023},
  archivePrefix = {arXiv},
  primaryClass  = {cs.CL},
  url           = {https://arxiv.org/abs/2604.07023}
}

@article{jin2026prove,
  title   = {ProVe: Proposer-Verifier Decoding},
  author  = {Jin, Ziqi and Xu, Weiwen and Li, Jiaxi and Zhong, Yujie and She, Qi and Sun, Aixin},
  journal = {arXiv preprint},
  year    = {2026}
}

Как запустить

На своей GPU в ailist. Цена — по текущим предложениям провайдеров

GPU в ailist

Универсальный рантайм · transformers

Нельзя запустить

Архитектура a2d-qwen2 неизвестна transformers в образе рантайма.

Класс архитектуры
A2DQwen2LMHeadModel
Ревизия весов
37658c4

0 моделей